Created
August 14, 2008 01:40
-
-
Save wycats/5346 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
>> module DataMapper; class Collection; alias_method :create_or_error, :create; end; end | |
=> DataMapper::Collection | |
>> Customer.first.environments.create_or_error | |
=> #<Environment created_at=nil updated_at=nil id=nil number=nil classification=nil description=nil cluster_id=nil customer_id=1> |
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
>> module DataMapper; class Collection; alias_method :create_or_error, :create; end; end | |
=> DataMapper::Collection | |
>> Customer.first.environments.create_or_error | |
=> #<Environment created_at=nil updated_at=nil id=nil number=nil classification=nil description=nil cluster_id=nil customer_id=nil> | |
>> Customer.first.environments.create | |
=> #<Environment created_at=nil updated_at=nil id=nil number=nil classification=nil description=nil cluster_id=nil customer_id=1> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment