chore(shared): remove extra NaN logic (#3837)

This commit is contained in:
Homyee King 2021-07-20 05:22:21 +08:00 committed by GitHub
parent 20b6619793
commit 65f82ce94f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -143,7 +143,7 @@ export const toHandlerKey = cacheStringFunction(
// compare whether a value has changed, accounting for NaN.
export const hasChanged = (value: any, oldValue: any): boolean =>
value !== oldValue && (value === value || oldValue === oldValue)
!Object.is(value, oldValue)
export const invokeArrayFns = (fns: Function[], arg?: any) => {
for (let i = 0; i < fns.length; i++) {