Exception: Organizations::MembershipVetoed

Inherits:
Error
  • Object
show all
Defined in:
lib/organizations.rb

Overview

Raised (typically by the host's on_member_joining gate) to VETO a membership that is about to be created — seat limits, member caps, compliance holds. The gate dispatches strictly inside the creating transaction, so raising this rolls everything back cleanly: no membership row, join requests stay pending (resumable), invitations stay unaccepted. Raising without a message gets the localized default (organizations.errors.membership_vetoed).

Instance Method Summary collapse

Constructor Details

#initialize(message = nil) ⇒ MembershipVetoed

Returns a new instance of MembershipVetoed.



69
70
71
# File 'lib/organizations.rb', line 69

def initialize(message = nil)
  super(message || Organizations.t(:"errors.membership_vetoed"))
end