-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
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
Add handling of arrays of objects #30
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is some really weird stuff that really should not be possible, but here we are. i've looked at it and am worried these things might break
src/arrayHandling.ts
Outdated
// handle properties of an object | ||
if (typeof item === "object") { | ||
const newReference = `$${reference.substring( | ||
reference.indexOf("#.") + 1, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thinking this could break in the scenario of nested $inarray
/$any
/$all
(unless im actually a coding genius and thought of that when building this function, which I might have, but still worth double checking)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought it might, but since it's actually checking if it's before before it returns something, it shouldn't. The code before it does something similar to this. There probably needs to be a test for this.
As title.