Exception: Apartment::PendingMigrationError
- Inherits:
-
ApartmentError
- Object
- StandardError
- ApartmentError
- Apartment::PendingMigrationError
- Defined in:
- lib/apartment/errors.rb
Overview
Raised in development when a tenant has pending migrations.
Instance Attribute Summary collapse
-
#tenant ⇒ Object
readonly
Returns the value of attribute tenant.
Instance Method Summary collapse
-
#initialize(tenant = nil) ⇒ PendingMigrationError
constructor
A new instance of PendingMigrationError.
Constructor Details
#initialize(tenant = nil) ⇒ PendingMigrationError
Returns a new instance of PendingMigrationError.
43 44 45 46 47 48 49 50 51 52 |
# File 'lib/apartment/errors.rb', line 43 def initialize(tenant = nil) @tenant = tenant super( if tenant "Tenant '#{tenant}' has pending migrations. Run apartment:migrate to update." else 'Tenant has pending migrations. Run apartment:migrate to update.' end ) end |
Instance Attribute Details
#tenant ⇒ Object (readonly)
Returns the value of attribute tenant.
41 42 43 |
# File 'lib/apartment/errors.rb', line 41 def tenant @tenant end |