I added the options hash because I thought it better to explicitly state what was the message and what was the error. This can be changed to my first commit, which just takes the message and error code as parameters. 

> On May 19, 2014, at 11:55 PM, Attila Domokos <notifications@github.com> wrote:
> 
> In lib/light-service/context.rb:
> 
> > @@ -60,8 +60,13 @@ def set_failure!(message)
> >        fail!(message)
> >      end
> >  
> > -    def fail!(message=nil)
> > -      @message = message
> > +    def fail!(options=nil)
> > +      if options.is_a? Hash
> > +        @message = options[:message]
> > +        @error_code = options[:error_code]
> > +      else
> > +        @message = options
> > +      end
> Why did you chose the options hash? I am wondering if using 2 arguments - with a default value for the last one if that's the error_code - would make this code simpler and easier to use.
> 
> —
> Reply to this email directly or view it on GitHub.