devise: unify password reset views
By default, Devise will look for views: 1. First in `views/resource/passwords/…`, 2. Then in `views/devise/passwords/…` if not found. By moving the views to `views/devise`, we avoid having a partial in `views/shared` that we need to include manually, and instead let Devise do the job automatically.
This commit is contained in:
parent
80f9d4adc0
commit
e5f449b595
7 changed files with 2 additions and 56 deletions
|
@ -1,14 +0,0 @@
|
|||
class Administrateurs::PasswordsController < ApplicationController
|
||||
def test_strength
|
||||
@score, @words, @length = ZxcvbnService.new(password_params[:password]).complexity
|
||||
@min_length = PASSWORD_MIN_LENGTH
|
||||
@min_complexity = PASSWORD_COMPLEXITY_FOR_ADMIN
|
||||
render 'shared/password/test_strength'
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def password_params
|
||||
params.require(:administrateur).permit(:password)
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue