Page MenuHomePhabricator

[native] Use `Array.some(...)` in `uploadInProgress`
ClosedPublic

Authored by abosh on Aug 19 2022, 2:13 PM.
Tags
None
Referenced Files
F3364923: D4892.id15798.diff
Mon, Nov 25, 5:48 AM
F3364481: D4892.diff
Mon, Nov 25, 3:59 AM
Unknown Object (File)
Wed, Nov 13, 7:46 AM
Unknown Object (File)
Fri, Nov 8, 3:43 AM
Unknown Object (File)
Mon, Oct 28, 5:08 AM
Unknown Object (File)
Mon, Oct 28, 5:08 AM
Unknown Object (File)
Mon, Oct 28, 5:05 AM
Unknown Object (File)
Oct 12 2024, 6:55 PM
Subscribers

Details

Summary

Depends on D4890. Minor change that avoids another level of indentation/for loop by using Array.some(...).

Test Plan

Flow, close reading.

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

tomek added inline comments.
native/input/input-state-container.react.js
376–378 ↗(On Diff #15798)

Using Object.values might simplify it even further

This revision is now accepted and ready to land.Aug 25 2022, 2:26 AM
abosh added inline comments.
native/input/input-state-container.react.js
376–378 ↗(On Diff #15798)

image.png (472×2 px, 197 KB)

Unfortunately Flow complains, but it is much cleaner!

native/input/input-state-container.react.js
376–378 ↗(On Diff #15798)

You can use values in lib/utils/objects.js

This revision was automatically updated to reflect the committed changes.
abosh marked an inline comment as done.