This commit is contained in:
Bilal
2020-09-08 17:05:36 +03:00
parent ac7e67c20e
commit 545d12f427

View File

@@ -31,7 +31,7 @@ class ApplicationController < ActionController::Base
end
def redirect_locked_accounts
if Current.user && !Current.user.admin? && Current.account.locked?
if Current.user && !Current.user.admin? && Current.account.present? && Current.account.locked?
redirect_to locked_account_path
end
end