Browse Source

show some instance info under whitelist_mode

closed-social-glitch-2
欧醚 1 year ago
parent
commit
66281b6dc8
5 changed files with 5 additions and 5 deletions
  1. +1
    -1
      app/controllers/api/v1/instances/domain_blocks_controller.rb
  2. +1
    -1
      app/controllers/api/v1/instances/extended_descriptions_controller.rb
  3. +1
    -1
      app/controllers/api/v1/instances/privacy_policies_controller.rb
  4. +1
    -1
      app/controllers/api/v1/instances/rules_controller.rb
  5. +1
    -1
      app/controllers/api/v1/instances_controller.rb

+ 1
- 1
app/controllers/api/v1/instances/domain_blocks_controller.rb View File

@ -1,7 +1,7 @@
# frozen_string_literal: true # frozen_string_literal: true
class Api::V1::Instances::DomainBlocksController < Api::BaseController class Api::V1::Instances::DomainBlocksController < Api::BaseController
skip_before_action :require_authenticated_user!, unless: :whitelist_mode?
skip_before_action :require_authenticated_user!
before_action :require_enabled_api! before_action :require_enabled_api!
before_action :set_domain_blocks before_action :set_domain_blocks

+ 1
- 1
app/controllers/api/v1/instances/extended_descriptions_controller.rb View File

@ -1,7 +1,7 @@
# frozen_string_literal: true # frozen_string_literal: true
class Api::V1::Instances::ExtendedDescriptionsController < Api::BaseController class Api::V1::Instances::ExtendedDescriptionsController < Api::BaseController
skip_before_action :require_authenticated_user!, unless: :whitelist_mode?
skip_before_action :require_authenticated_user!
before_action :set_extended_description before_action :set_extended_description

+ 1
- 1
app/controllers/api/v1/instances/privacy_policies_controller.rb View File

@ -1,7 +1,7 @@
# frozen_string_literal: true # frozen_string_literal: true
class Api::V1::Instances::PrivacyPoliciesController < Api::BaseController class Api::V1::Instances::PrivacyPoliciesController < Api::BaseController
skip_before_action :require_authenticated_user!, unless: :whitelist_mode?
skip_before_action :require_authenticated_user!
before_action :set_privacy_policy before_action :set_privacy_policy

+ 1
- 1
app/controllers/api/v1/instances/rules_controller.rb View File

@ -1,7 +1,7 @@
# frozen_string_literal: true # frozen_string_literal: true
class Api::V1::Instances::RulesController < Api::BaseController class Api::V1::Instances::RulesController < Api::BaseController
skip_before_action :require_authenticated_user!, unless: :whitelist_mode?
skip_before_action :require_authenticated_user!
before_action :set_rules before_action :set_rules

+ 1
- 1
app/controllers/api/v1/instances_controller.rb View File

@ -2,7 +2,7 @@
class Api::V1::InstancesController < Api::BaseController class Api::V1::InstancesController < Api::BaseController
skip_before_action :set_cache_headers skip_before_action :set_cache_headers
skip_before_action :require_authenticated_user!, unless: :whitelist_mode?
skip_before_action :require_authenticated_user!
def show def show
expires_in 3.minutes, public: true expires_in 3.minutes, public: true

Loading…
Cancel
Save