Treequel::

BeforeHookFailed

class
Superclass
Treequel::ModelError

Exception class raised when a before_* hooks returns a false value when saving or destroying a Treequel::Model object.

Attributes

hook[R]

The hook that failed

Public Class Methods

anchor
new( hook )

Create a new Treequel::BeforeHookFailed exception that indicates that the specified hook returned a false value.

# File lib/treequel/exceptions.rb, line 57
def initialize( hook )
        @hook = hook.to_sym
        super "The 'before' hook failed when trying to %s" % [ hook ]
end