Use ReadableNativeMap equality on UpdateLocalData (#23408)

Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/23408

Use equals method in the updateLocalData method

Reviewed By: JoshuaGross

Differential Revision: D14026378

fbshipit-source-id: 762559276a1fe63035e0f5d055620f95b8f62fb0
This commit is contained in:
David Vacca
2019-02-17 11:03:13 -08:00
committed by Facebook Github Bot
parent f4536422d6
commit 3102ea51b2

View File

@@ -250,8 +250,7 @@ public class MountingManager {
if (viewState.mCurrentLocalData != null
&& newLocalData.hasKey("hash")
&& viewState.mCurrentLocalData.getDouble("hash") == newLocalData.getDouble("hash")
&& viewState.mCurrentLocalData.toString().equals(newLocalData.toString())) {
// TODO: T31905686 implement a proper equality method
&& viewState.mCurrentLocalData.equals(newLocalData)) {
return;
}
viewState.mCurrentLocalData = newLocalData;