aboutsummaryrefslogtreecommitdiffstats
path: root/app/controllers/application_controller.rb
diff options
context:
space:
mode:
authorRhenium <rhenium@rhe.jp>2013-11-17 06:30:31 +0900
committerRhenium <rhenium@rhe.jp>2013-11-17 06:30:31 +0900
commitf54b2d0a4ab55167cc141e2549db05477c83e9df (patch)
tree77191009910409f0370405ddf1a7846a03ace463 /app/controllers/application_controller.rb
parent546bd0726afa3a7a86a6559e51fadcda03aeff22 (diff)
downloadaclog-f54b2d0a4ab55167cc141e2549db05477c83e9df.tar.gz
move ApplicationController#_get_user to User.get
Diffstat (limited to 'app/controllers/application_controller.rb')
-rw-r--r--app/controllers/application_controller.rb8
1 files changed, 0 insertions, 8 deletions
diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb
index 819ef93..37a7820 100644
--- a/app/controllers/application_controller.rb
+++ b/app/controllers/application_controller.rb
@@ -10,14 +10,6 @@ class ApplicationController < ActionController::Base
protected
def logged_in?; session[:user_id] && session[:account] end
- def _get_user(id, screen_name)
- if id
- User.find(id) rescue raise Aclog::Exceptions::UserNotFound
- elsif screen_name
- User.find_by(screen_name: screen_name) or raise Aclog::Exceptions::UserNotFound
- end
- end
-
def authorized_to_show_user?(user)
@authorized_to_show_user ||= {}
@authorized_to_show_user[user.id] ||= begin