lib/surrogate/method_definition.rb in surrogate-0.6.5 vs lib/surrogate/method_definition.rb in surrogate-0.7.0

- old
+ new

@@ -24,16 +24,16 @@ def must_match!(args) default_proc && errorizer.match!(*args) end - def default(instance, invocation, &no_default) + def default(instance, invocation) if options.has_key? :default options[:default] elsif default_proc default_proc_as_method_on(instance).call(*invocation.args, &invocation.block) else - no_default.call + raise "You should never get here. Please open a issue at http://github.com/JoshCheek/surrogate" end end private