Skip to content

Fix missing HttpContext on ValidationContext during atomic operations #1251

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

Merged
merged 1 commit into from
Feb 4, 2023
Merged

Fix missing HttpContext on ValidationContext during atomic operations #1251

merged 1 commit into from
Feb 4, 2023

Conversation

Tommy228
Copy link
Contributor

@Tommy228 Tommy228 commented Jan 30, 2023

Closes #1250

This PR

  • Adds HttpContext to the ValidationContext when validating objects during atomic operations, allowing dependency injection
  • Adds a test case to the integration tests to validate this

QUALITY CHECKLIST

@Tommy228 Tommy228 marked this pull request as draft January 30, 2023 18:49
@Tommy228 Tommy228 marked this pull request as ready for review January 30, 2023 18:55
@codecov
Copy link

codecov bot commented Jan 30, 2023

Codecov Report

Merging #1251 (1e343e7) into master (c7e396d) will increase coverage by 0.00%.
The diff coverage is 100.00%.

❗ Current head 1e343e7 differs from pull request most recent head ffa5015. Consider uploading reports for the commit ffa5015 to get more accurate results

@@           Coverage Diff           @@
##           master    #1251   +/-   ##
=======================================
  Coverage   92.62%   92.62%           
=======================================
  Files         243      243           
  Lines        7795     7796    +1     
=======================================
+ Hits         7220     7221    +1     
  Misses        575      575           
Impacted Files Coverage Δ
...ore/Controllers/BaseJsonApiOperationsController.cs 100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@bkoelman
Copy link
Member

Hi @Tommy228, thanks for your contribution! I intend to look at it somewhere this week.

Copy link
Member

@bkoelman bkoelman left a comment

Choose a reason for hiding this comment

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

Thanks for carefully adhering to our code style and naming conventions. See comments below.

@Tommy228 Tommy228 requested a review from bkoelman January 31, 2023 22:44
@Tommy228 Tommy228 requested a review from bkoelman February 3, 2023 18:16
@bkoelman bkoelman merged commit c835ff2 into json-api-dotnet:master Feb 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

ValidationContext does not have a ServiceProvider on atomic operations
2 participants