Skip to content

Instantly share code, notes, and snippets.

@cored
Created June 14, 2013 15:13
Show Gist options
  • Save cored/5782645 to your computer and use it in GitHub Desktop.
Save cored/5782645 to your computer and use it in GitHub Desktop.
def attribute(name, *args)
equalizer << name
if args.size > 2
require 'pry'; binding.pry
end
options = args.last.kind_of?(Hash) ? args.pop : {}
sender = *args << options.merge(:writer => :private)
super name, sender
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment