Created
August 23, 2009 00:13
-
-
Save linojon/173060 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## app/controllers/application_controller.rb | |
helper :all | |
protect_from_forgery | |
include Authentication | |
## lib/authentication.rb | |
module Authentication | |
filter_parameter_logging :password, :password_confirmation | |
helper_method :current_user | |
private | |
def current_user | |
return @current_user if defined?(@current_user) | |
@current_user = current_user_session && current_user_session.user | |
end | |
end | |
## | |
when i move the filter_parameter_logging and helper_method into application_controller.rb its all good |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment