From e80898409cf5d343e78ff1cef79f0af077185420 Mon Sep 17 00:00:00 2001 From: Fire Demon Date: Tue, 18 Aug 2020 00:49:37 -0500 Subject: [Privacy] Only consider being locally logged in "authenticated" in authenticated_or_following --- app/controllers/application_controller.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb index 2b58e0b90..8154924b9 100644 --- a/app/controllers/application_controller.rb +++ b/app/controllers/application_controller.rb @@ -69,7 +69,7 @@ class ApplicationController < ActionController::Base end def require_functional! - redirect_to edit_user_registration_path unless current_user.functional? + redirect_to edit_user_registration_path unless current_user&.functional? end def require_authenticated! @@ -259,7 +259,7 @@ class ApplicationController < ActionController::Base end def authenticated_or_following?(account) - current_account? || following?(account) + current_user&.account.present? || following?(account) end def current_account? -- cgit