-
Notifications
You must be signed in to change notification settings - Fork 212
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
chore: Resolve Array.forEach lint warnings #9688
Conversation
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 was skeptical about the value of this lint rule, but many of the changes are in fact more readable (particularly those in which the iterator result value is destructured or when construction of a temporary Array is no longer necessary).
c7687e8
to
bb2ce5e
Compare
Deploying agoric-sdk with Cloudflare Pages
|
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.
Looks good. Thanks for taking this.
Co-authored-by: Richard Gibson <richard.gibson@gmail.com>
Co-authored-by: Richard Gibson <richard.gibson@gmail.com>
74ad576
to
363f83f
Compare
Ref #9632
Description
Replaced
Array.forEach();
calls withfor ( x of y ) { };
loops.Security Considerations
Assume that Array.forEach() calls are equivalent to
for ( x of y ) { };
in all cases.Scaling Considerations
No significant difference expected.
Documentation Considerations
N/A
Testing Considerations
No new tests required. Local tests passed, including lint (specific to this PR).
Upgrade Considerations
The change preserves the behavior, thus there are no upgrade concerns.