Exception: Suture::Error::SchemaVersion
- Inherits:
-
StandardError
- Object
- StandardError
- Suture::Error::SchemaVersion
- Defined in:
- lib/suture/error/schema_version.rb
Instance Method Summary collapse
-
#initialize(expected, actual) ⇒ SchemaVersion
constructor
A new instance of SchemaVersion.
- #message ⇒ Object
Constructor Details
#initialize(expected, actual) ⇒ SchemaVersion
Returns a new instance of SchemaVersion.
3 4 5 6 |
# File 'lib/suture/error/schema_version.rb', line 3 def initialize(expected, actual) @expected = expected @actual = actual end |
Instance Method Details
#message ⇒ Object
8 9 10 |
# File 'lib/suture/error/schema_version.rb', line 8 def "Your suture gem is too #{@expected > @actual ? "new" : "old"} for this schema. Either delete your database or #{@expected > @actual ? "upgrade" : "downgrade"} the gem (expected schema version #{@expected}, was #{@actual})" end |