fix nil related error on edit account page

the error was 'undefined method `password_required?' for nil:NilClass'