diff options
Diffstat (limited to 'app/helpers/application_helper.rb')
-rw-r--r-- | app/helpers/application_helper.rb | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index c5374a195..af453825b 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -204,7 +204,7 @@ module ApplicationHelper permit_visibilities.shift(permit_visibilities.index(default_privacy) + 1) if default_privacy.present? state_params[:visibility] = params[:visibility] if permit_visibilities.include? params[:visibility] - if user_signed_in? + if user_signed_in? && current_user.functional? state_params[:settings] = state_params[:settings].merge(Web::Setting.find_by(user: current_user)&.data || {}) state_params[:push_subscription] = current_account.user.web_push_subscription(current_session) state_params[:current_account] = current_account @@ -212,6 +212,11 @@ module ApplicationHelper state_params[:admin] = Account.find_local(Setting.site_contact_username.strip.gsub(/\A@/, '')) end + if user_signed_in? && !current_user.functional? + state_params[:disabled_account] = current_account + state_params[:moved_to_account] = current_account.moved_to_account + end + if single_user_mode? state_params[:owner] = Account.local.without_suspended.where('id > 0').first end |