Replies: 1 comment
-
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I couldn't find any documentation around using
#to_a
on datasets, but in practice it appeared that#to_a
and#all
were the same. However, today I ran into a case where, after using#eager_graph
,#all
returns model instances, but#to_a
returns hashes.Is there any documentation on using
#to_a
versus#all
and what the expected behavior is for each?I actually couldn't find any documentation of
#to_a
, so I am assuming that this is actually just the ruby core method being used on an enumerable and thus the behavior may be inconsistent - thus we should always prefer using the#all
method. Is that correct?Beta Was this translation helpful? Give feedback.
All reactions