Skip to content

Instantly share code, notes, and snippets.

@thoughtbot
Created August 4, 2009 21:23
Show Gist options
  • Select an option

  • Save thoughtbot/161567 to your computer and use it in GitHub Desktop.

Select an option

Save thoughtbot/161567 to your computer and use it in GitHub Desktop.
module Addressable
def self.included(klazz) # klazz is that class object that @include@d this module
klazz.class_eval do
has_one :address
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment