chore: Allow super admin to suspend an account (#5174)
This commit is contained in:
@@ -5,7 +5,9 @@ module WebsiteTokenHelper
|
||||
|
||||
def set_web_widget
|
||||
@web_widget = ::Channel::WebWidget.find_by!(website_token: permitted_params[:website_token])
|
||||
@current_account = @web_widget.account
|
||||
@current_account = @web_widget.inbox.account
|
||||
|
||||
render json: { error: 'Account is suspended' }, status: :unauthorized unless @current_account.active?
|
||||
end
|
||||
|
||||
def set_contact
|
||||
|
||||
Reference in New Issue
Block a user