mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Avoid repeated value read in SubtractionAnimatedNode
Summary: Minor optimization, but spotted this while reviewing the implementation for D33622997 Changelog: [Internal] Reviewed By: mdvacca Differential Revision: D33622996 fbshipit-source-id: 8712753803fc46e6a046d50f77454a813e4a641a
This commit is contained in:
committed by
Facebook GitHub Bot
parent
b2105711a0
commit
08e76772fe
@@ -41,7 +41,7 @@ import com.facebook.react.bridge.ReadableMap;
|
||||
AnimatedNode animatedNode = mNativeAnimatedNodesManager.getNodeById(mInputNodeTag);
|
||||
if (animatedNode == null || !(animatedNode instanceof ValueAnimatedNode)) {
|
||||
throw new JSApplicationCausedNativeException(
|
||||
"Illegal node ID set as an input for " + "Animated.DiffClamp node");
|
||||
"Illegal node ID set as an input for Animated.DiffClamp node");
|
||||
}
|
||||
|
||||
return ((ValueAnimatedNode) animatedNode).getValue();
|
||||
|
||||
Reference in New Issue
Block a user