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

Create AuthoredHintViewRequests only if current_user. #13179

Merged
merged 3 commits into from Feb 13, 2017

Conversation

ashercodeorg
Copy link
Contributor

@ashercodeorg ashercodeorg commented Feb 10, 2017

On 2017-02-09, it was discovered that we have been creating AuthoredHintViewRequest records for all users, signed-in or non-signed-in. This PR makes it so that we only create records for signed-in users, the desired behavior.

TODO(asher, hamms) (here and in follow-up PRs):

  • (hamms) Fix the client-side logic to stop making controller requests for non-signed-in users.
  • (hamms) Update the controller and test to return a :bad_request rather than :accepted for non-signed-in users.
  • (asher) Remove all AuthoredHintViewRequest data from the DB associated with non-signed-in users.
  • (asher) Make AuthoredHintViewRequest.user_id a non-nullable column.

Also includes readability and style cleanup.

@codecov-io
Copy link

Codecov Report

Merging #13179 into staging will not change coverage.

@@           Coverage Diff            @@
##           staging   #13179   +/-   ##
========================================
  Coverage    58.01%   58.01%           
========================================
  Files          711      711           
  Lines        52109    52109           
  Branches      1154     1154           
========================================
  Hits         30232    30232           
  Misses       21672    21672           
  Partials       205      205
Flag Coverage Δ
#integration 49.78% <100%> (ø)
#unit 41.35% <100%> (ø)
Impacted Files Coverage Δ
apps/src/StudioApp.js 59.52% <100%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5b95199...1b89e32. Read the comment docs.

@ashercodeorg
Copy link
Contributor Author

LGTM your commits, @Hamms.

@ashercodeorg ashercodeorg merged commit 8593bd2 into staging Feb 13, 2017
@ashercodeorg ashercodeorg deleted the fixAuthoredHintTests branch February 13, 2017 17:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants