class Treequel::BeforeHookFailed
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
new( hook )
click to toggle source
Create a new Treequel::BeforeHookFailed
exception that indicates that the specified hook
returned a false value.
Calls superclass method
# 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