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

problem: logged out users can still access forms #393

Closed
gsovereignty opened this issue Nov 1, 2018 · 9 comments
Closed

problem: logged out users can still access forms #393

gsovereignty opened this issue Nov 1, 2018 · 9 comments
Labels
done Problem is solved, waiting for confirmation to close

Comments

@gsovereignty
Copy link
Member

problem: logged out users can still access forms, which will really annoying because users might fill out the form but then realize they are not logged in and lose all their work.

solution: send logged out users to login page whenever trying to access forms. All forms site wide must be checked.

@venatoria
Copy link
Collaborator

venatoria commented Nov 1, 2018

solution : every form template needs to be included in a test about the login status of the user.
{{if currentUser}}
TemplateContent
{{else}}
{{>login}}
{{/if}}

@anbud
Copy link
Member

anbud commented Nov 1, 2018

@venatoria, you can also test this in the router, before rendering the template at all. It's maybe simpler.

@venatoria
Copy link
Collaborator

@anbud my first thought was to implement on the templates.
All forms has defined routes.. So yes, the optimal solution would be to fix it there.
I'm submitting using the routes solution.

@gsovereignty
Copy link
Member Author

@venatoria if you're working on this now, you should do @emurgobot claim to claim it so that no one else works on it at the same time as you.

@venatoria
Copy link
Collaborator

@emurgobot claim

@emurgobot
Copy link
Member

Welcome to Zulip, @venatoria! We just sent you an invite to collaborate on this repository at https://github.com/EmurgoHK/cardanoupdate/invitations. Please accept this invite in order to claim this issue and begin a fun, rewarding experience contributing to Zulip!

Here's some tips to get you off to a good start:

As you work on this issue, you'll also want to refer to the Zulip code contribution guide, as well as the rest of the developer documentation on that site.

See you on the other side (that is, the pull request side)!

1 similar comment
@emurgobot
Copy link
Member

Welcome to Zulip, @venatoria! We just sent you an invite to collaborate on this repository at https://github.com/EmurgoHK/cardanoupdate/invitations. Please accept this invite in order to claim this issue and begin a fun, rewarding experience contributing to Zulip!

Here's some tips to get you off to a good start:

As you work on this issue, you'll also want to refer to the Zulip code contribution guide, as well as the rest of the developer documentation on that site.

See you on the other side (that is, the pull request side)!

@emurgobot emurgobot added the in progress Someone is working on this issue label Nov 1, 2018
venatoria added a commit to venatoria/cardanoupdate that referenced this issue Nov 1, 2018
soluiton: add a filter to the routes related to the forms that triggers a check on login.
this solves issue EmurgoHK#393
@venatoria
Copy link
Collaborator

@emurgobot label "done"

@emurgobot emurgobot added the done Problem is solved, waiting for confirmation to close label Nov 1, 2018
MadanBhandari added a commit that referenced this issue Nov 1, 2018
problem: logged out users can still access forms (issue #393)
@MadanBhandari
Copy link
Member

Hey @venatoria

You don't need to change label after sending PR you can just comment

@emurgobot done in #PR_NUMBER

This will automatically unassigned you and add label done :)

@MadanBhandari MadanBhandari removed the in progress Someone is working on this issue label Nov 1, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
done Problem is solved, waiting for confirmation to close
Projects
None yet
Development

No branches or pull requests

5 participants