-
Notifications
You must be signed in to change notification settings - Fork 4
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
Feature: MFA for admins #635
Conversation
cccb39f
to
eb3647c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Nice to see this flow enabled.
Some minor thoughts for additional tests, possible security, and clarity.
drift_ahead: 15, | ||
drift_behind: 15, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(opt) Use constants for magic numbers
redirect_to(url_from(params[:redirect].presence) || admin_dashboard_path, status: :see_other) | ||
else | ||
admin_user = Admin::User.new | ||
admin_user.errors.add(:email, "Invalid token") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(opt) If we use a locale entry, it should be possible to overwrite this on a per-app basis
redirect_to(url_from(params[:redirect].presence) || admin_dashboard_path, status: :see_other) | ||
else | ||
admin_user = Admin::User.new | ||
admin_user.errors.add(:email, "Invalid login credentials") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
as above
eb3647c
to
c82b38b
Compare
No description provided.