From aa4dbf0f06ce1904adf0d9f25c35f3b4feddfa34 Mon Sep 17 00:00:00 2001 From: p31729568 Date: Thu, 11 Jul 2019 16:31:18 +0800 Subject: [PATCH] account manange not check profile complete --- app/controllers/users/base_account_controller.rb | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/app/controllers/users/base_account_controller.rb b/app/controllers/users/base_account_controller.rb index b693eaab5..29de52b26 100644 --- a/app/controllers/users/base_account_controller.rb +++ b/app/controllers/users/base_account_controller.rb @@ -4,4 +4,12 @@ class Users::BaseAccountController < Users::BaseController def observed_user @_observed_user ||= (User.find_by_id(params[:account_id]) || User.find_by_login(params[:account_id])) end + + private + + def require_login + return if User.current.logged? + + tip_exception(401, "..") + end end