Refactor: replace whitelist_mode mentions with limited_federation_mode (#26252)

This commit is contained in:
Emelia Smith authored and GitHub committed 2023-08-02 19:32:48 +02:00
1 parent 8891d8945d
commit e258b4cb64
33 files changed
+57 -55

No files matched your search

@@ -1,14 +1,14 @@
# frozen_string_literal: true
class Api::V1::InstancesController < Api::BaseController
skip_before_action :require_authenticated_user!, unless: :whitelist_mode?
skip_before_action :require_authenticated_user!, unless: :limited_federation_mode?
skip_around_action :set_locale
vary_by ''
# Override `current_user` to avoid reading session cookies unless in whitelist mode
def current_user
super if whitelist_mode?
super if limited_federation_mode?
end
def show