diff --git a/app/components/post_list/__snapshots__/post_list.test.js.snap b/app/components/post_list/__snapshots__/post_list.test.js.snap index 19cd8138a..ac0e6c40b 100644 --- a/app/components/post_list/__snapshots__/post_list.test.js.snap +++ b/app/components/post_list/__snapshots__/post_list.test.js.snap @@ -36,7 +36,7 @@ exports[`PostList setting channel deep link 1`] = ` "minIndexForVisible": 0, } } - maxToRenderPerBatch={5} + maxToRenderPerBatch={10} numColumns={1} onContentSizeChange={[Function]} onEndReachedThreshold={2} @@ -65,7 +65,7 @@ exports[`PostList setting channel deep link 1`] = ` } } updateCellsBatchingPeriod={50} - windowSize={11} + windowSize={50} /> `; @@ -105,7 +105,7 @@ exports[`PostList setting permalink deep link 1`] = ` "minIndexForVisible": 0, } } - maxToRenderPerBatch={5} + maxToRenderPerBatch={10} numColumns={1} onContentSizeChange={[Function]} onEndReachedThreshold={2} @@ -134,7 +134,7 @@ exports[`PostList setting permalink deep link 1`] = ` } } updateCellsBatchingPeriod={50} - windowSize={11} + windowSize={50} /> `; @@ -174,7 +174,7 @@ exports[`PostList should match snapshot 1`] = ` "minIndexForVisible": 0, } } - maxToRenderPerBatch={5} + maxToRenderPerBatch={10} numColumns={1} onContentSizeChange={[Function]} onEndReachedThreshold={2} @@ -203,6 +203,6 @@ exports[`PostList should match snapshot 1`] = ` } } updateCellsBatchingPeriod={50} - windowSize={11} + windowSize={50} /> `; diff --git a/app/components/post_list/post_list.js b/app/components/post_list/post_list.js index 9bca7236a..ab860af88 100644 --- a/app/components/post_list/post_list.js +++ b/app/components/post_list/post_list.js @@ -3,7 +3,7 @@ import React, {PureComponent} from 'react'; import PropTypes from 'prop-types'; -import {Alert, FlatList, InteractionManager, RefreshControl, StyleSheet} from 'react-native'; +import {Alert, FlatList, InteractionManager, Platform, RefreshControl, StyleSheet} from 'react-native'; import {intlShape} from 'react-intl'; import EventEmitter from 'mattermost-redux/utils/event_emitter'; @@ -514,6 +514,7 @@ export default class PostList extends PureComponent { tintColor={theme.centerChannelColor} />); + const hasPostsKey = postIds.length ? 'true' : 'false'; return ( ); }