Skip to content

Enable ORM to accept attributes named 'length'#87

Merged
mikermcneil merged 1 commit intosailshq:masterfrom
danielsharvey:patch-1
May 11, 2018
Merged

Enable ORM to accept attributes named 'length'#87
mikermcneil merged 1 commit intosailshq:masterfrom
danielsharvey:patch-1

Conversation

@danielsharvey
Copy link
Contributor

Replace _.each() with _.forIn() to enable ORM to accept attributes named 'length'.

See balderdashy/sails#4353

Replace `_.each()` with `_.forIn()` to enable ORM to accept attributes named 'length'.

See balderdashy/sails#4353
// Process each key in the record and build up a child record that can
// then be nested into the parent.
_.each(record, function checkForChildren(val, key) {
_.forIn(record, function checkForChildren(val, key) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For posterity:
image

@mikermcneil mikermcneil merged commit 9486b92 into sailshq:master May 11, 2018
@mikermcneil
Copy link
Member

@danielsharvey thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants