Last active
June 25, 2017 11:48
-
-
Save mariorcardoso/da7452a8ffaa46213630694bad4889c9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Person < ActiveRecord::Base | |
def address | |
Address.new(address_city, address_state) | |
end | |
def address=(address) | |
self.address_city = address.city | |
self.address_state = address.state | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment