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

Surveys: Grooming of messages to user #2651

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

differentreality
Copy link
Contributor

@differentreality differentreality commented Mar 29, 2020

Checklist

  • I have read the Contribution & Best practices Guide.
  • My branch is up-to-date with the upstream master branch.
  • The tests pass locally with my changes.
  • I have added tests that prove my fix is effective or that my feature works(if appropriate).
  • I have added necessary documentation (if appropriate).

Short description of what this resolves/which issues does this fix?:

#2639

Changes proposed in this pull request:

  • Groom error message when survey is closed
  • Add flash success and error message for when user replies
  • Show Back link (for surveys during_registration and after_event)

else
@survey.survey_submissions.create!(user: current_user)
end
rescue => error
Copy link
Member

Choose a reason for hiding this comment

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

Hm, how can this happen?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

If we cannot create the submission record (when create! raises an exception)

Copy link
Member

Choose a reason for hiding this comment

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

Sure but I don't see any condition when this will happen? Only when the user already has submitted. Isn't all of this just some for of find_or_create_by?

@hennevogel hennevogel force-pushed the actions_after_survey_submission branch from 720e23c to 4d5bb42 Compare March 6, 2021 18:25
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