Fix empty viewableItems check

This commit is contained in:
Diego Mello 2022-12-07 16:28:31 -03:00
parent fd82771438
commit 976753c08b
1 changed files with 1 additions and 1 deletions

View File

@ -186,7 +186,7 @@ class ListContainer extends React.Component<IListContainerProps, IListContainerS
if (this.mounted) {
this.setState({ messages: data });
if (this.animated && this.viewableItems?.[0].index === 0) {
if (this.animated && this.viewableItems?.[0]?.index === 0) {
listRef.current?.prepareForLayoutAnimationRender();
animateNextTransition();
}