Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Handle EmptyContent #48

Merged
merged 1 commit into from
Oct 28, 2024
Merged

Handle EmptyContent #48

merged 1 commit into from
Oct 28, 2024

Conversation

HugoBurgess
Copy link
Contributor

PR Classification

Code cleanup to improve robustness and compatibility across .NET versions.

PR Summary

Introduced a new method HasContent to handle HttpResponseMessage.Content checks more reliably.

  • Result class: Added HasContent method to check if HttpResponseMessage.Content is not null and not EmptyContent.
  • Updated WithStreamData, WithObjectData, and CreateResultAsync methods to use HasContent for content checks.
  • Removed unnecessary whitespace changes in ReadAsTypeAsync and ReadAsStreamAsync methods.

@HugoBurgess HugoBurgess requested review from rockydevnet and a team as code owners October 25, 2024 16:24
Copy link
Collaborator

@JiviteshT JiviteshT left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@HugoBurgess HugoBurgess merged commit e52af15 into main Oct 28, 2024
3 checks passed
@HugoBurgess HugoBurgess deleted the Feature/Abzu-176981-empty-content branch October 28, 2024 09:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants