diff options
author | jessib <jessib@riseup.net> | 2012-10-17 10:12:11 -0700 |
---|---|---|
committer | jessib <jessib@riseup.net> | 2012-10-17 10:12:11 -0700 |
commit | c072a2fe1d50715bad1cd8c14213cba6aa1cc8ff (patch) | |
tree | 14a599dadbe440952c0de73c487113bc09aa9142 /app/controllers | |
parent | 171d07a64d3f76e68c22f0fb4cc3795daad806d1 (diff) | |
parent | d9a510fa2126c29f0af58c6bbeff35802777eee6 (diff) |
Merge branch 'develop' into help_develop
Diffstat (limited to 'app/controllers')
-rw-r--r-- | app/controllers/application_controller.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index e8065d9..693bd86 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -1,3 +1,10 @@ class ApplicationController < ActionController::Base protect_from_forgery + + helper_method :current_user + + private + def current_user + @current_user ||= User.find(session[:user_id]) if session[:user_id] + end end |