Skip to content

Commit 629e10e

Browse files
sammy-SCfacebook-github-bot
authored andcommitted
Fix "Cannot read property 'getNativeScrollRef' of undefined" in createAnimatedComponent
Summary: Changelog: Fix "Cannot read property 'getNativeScrollRef' of undefined" error in createAnimatedComponent Reviewed By: JoshuaGross Differential Revision: D22897211 fbshipit-source-id: d4f5161ac908fd137b2332a6860e62ad1cfd8856
1 parent 83edd0c commit 629e10e

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Libraries/Animated/src/createAnimatedComponent.js

+1
Original file line numberDiff line numberDiff line change
@@ -101,6 +101,7 @@ function createAnimatedComponent<Props: {+[string]: mixed, ...}, Instance>(
101101
this._component.getNativeScrollRef()['_internalInstanceHandle']
102102
?.stateNode?.canonical != null) ||
103103
(this._component.getScrollResponder != null &&
104+
this._component.getScrollResponder() != null &&
104105
this._component.getScrollResponder().getNativeScrollRef != null &&
105106
this._component.getScrollResponder().getNativeScrollRef() != null &&
106107
this._component.getScrollResponder().getNativeScrollRef()[

0 commit comments

Comments
 (0)