lib/textbringer/utils.rb in textbringer-0.2.7 vs lib/textbringer/utils.rb in textbringer-0.2.8

- old
+ new

@@ -309,10 +309,10 @@ end end HOOKS = Hash.new { |h, k| h[k] = [] } - def add_hook(name, func) + def add_hook(name, func = Proc.new) HOOKS[name].unshift(func) end def remove_hook(name, func) HOOKS[name].delete(func)