Skip to content
This repository has been archived by the owner on Mar 6, 2024. It is now read-only.

Commit

Permalink
fix: set ConsultationPolicy#index?
Browse files Browse the repository at this point in the history
  • Loading branch information
darccio committed Feb 22, 2023
1 parent 4c2c1cb commit 945fc09
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions app/policies/consultation_policy.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
# frozen_string_literal: true

class ConsultationPolicy < ApplicationPolicy
def index?
return current_user.admin? if Rails.configuration.x.asembleo.private_instance

false
end

def create?
return current_user.admin? if Rails.configuration.x.asembleo.private_instance

Expand Down

0 comments on commit 945fc09

Please sign in to comment.