File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -101,6 +101,9 @@ class TransitionGroup extends React.Component {
101
101
102
102
_handleDoneAppearing = ( key ) => {
103
103
let component = this . childRefs [ key ] ;
104
+ if ( ! component ) {
105
+ return ;
106
+ }
104
107
if ( component . componentDidAppear ) {
105
108
component . componentDidAppear ( ) ;
106
109
}
@@ -131,6 +134,9 @@ class TransitionGroup extends React.Component {
131
134
132
135
_handleDoneEntering = ( key ) => {
133
136
let component = this . childRefs [ key ] ;
137
+ if ( ! component ) {
138
+ return ;
139
+ }
134
140
if ( component . componentDidEnter ) {
135
141
component . componentDidEnter ( ) ;
136
142
}
@@ -161,7 +167,10 @@ class TransitionGroup extends React.Component {
161
167
162
168
_handleDoneLeaving = ( key ) => {
163
169
let component = this . childRefs [ key ] ;
164
-
170
+
171
+ if ( ! component ) {
172
+ return ;
173
+ }
165
174
if ( component . componentDidLeave ) {
166
175
component . componentDidLeave ( ) ;
167
176
}
You can’t perform that action at this time.
0 commit comments