28 Jul
2005
28 Jul
'05
11:41 a.m.
I like what we have now: An array when it is a recurring 'thing'. An object when that thing is a single wel... 'object'.
You don't want to iterated through all fields of a user, for they have all different kinds of functions. Hence it is an object. But a list of terms associated with a node comes as an array. Because you will most likely want to iterate over it and perform the same action to each entry. I'm fine with this logic. We should probably put an explicit explanation somewhere in the docs, for example in the coding style guidelines. I think there is a tendency to use objects vs arrays for estetic reasons only, which makes no real sense IMO.
Vlado