Module: TenantLevelSecurity::CommandRecorder

Defined in:
lib/activerecord-tenant-level-security/command_recorder.rb

Instance Method Summary collapse

Instance Method Details

#create_policy(*args) ⇒ Object



3
4
5
# File 'lib/activerecord-tenant-level-security/command_recorder.rb', line 3

def create_policy(*args)
  record(:create_policy, args)
end

#invert_create_policy(args) ⇒ Object



11
12
13
# File 'lib/activerecord-tenant-level-security/command_recorder.rb', line 11

def invert_create_policy(args)
  [:remove_policy, args]
end

#invert_remove_policy(args) ⇒ Object



15
16
17
# File 'lib/activerecord-tenant-level-security/command_recorder.rb', line 15

def invert_remove_policy(args)
  [:create_policy, args]
end

#remove_policy(*args) ⇒ Object



7
8
9
# File 'lib/activerecord-tenant-level-security/command_recorder.rb', line 7

def remove_policy(*args)
  record(:remove_policy, args)
end