Refactor settings controllers (#14767)

- Disallow suspended accounts from revoking sessions and apps
- Allow suspended accounts to access exports
This commit is contained in:
Eugen Rochko authored and GitHub committed 2020-09-11 20:56:35 +02:00
1 parent e6b272e5c9
commit 4e4b3a0c8e
31 files changed
+65 -118

No files matched your search

@@ -5,7 +5,6 @@ module ExportControllerConcern
included do
before_action :authenticate_user!
before_action :require_not_suspended!
before_action :load_export
skip_before_action :require_functional!
@@ -30,8 +29,4 @@ module ExportControllerConcern
def export_filename
"#{controller_name}.csv"
end
def require_not_suspended!
forbidden if current_account.suspended?
end
end