We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The code:
lego = Group.seed(:name) do |s| s.id = 1 s.name = 'lego' s.max = 2 end puts '@' + lego.id.to_s
The output:
- Group {:max=>2, :name=>"lego", :id=>1} @70059737238420
It's terribly broken because there is a built-in method id in Object class. How to access the ID field?
id
The text was updated successfully, but these errors were encountered:
Lol, I was able to work-around it with lego[0].id. Please fix it. :)
lego[0].id
Sorry, something went wrong.
#seed method returns array, so that is not a bug actually... But it is confusing to get array when using block.
#seed
No branches or pull requests
The code:
The output:
It's terribly broken because there is a built-in method
id
in Object class. How to access the ID field?The text was updated successfully, but these errors were encountered: