MoreFollows: Only show when all follows have been loaded

stable/1.0.x
Alex Gleason 2020-06-07 15:09:25 -05:00
rodzic 409431d7e8
commit 886b241433
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 7211D1F99744FBB7
1 zmienionych plików z 2 dodań i 1 usunięć

Wyświetl plik

@ -207,9 +207,10 @@ export default class ScrollableList extends PureComponent {
}
getMoreFollows = () => {
const { scrollKey, isLoading, diffCount } = this.props;
const { scrollKey, isLoading, diffCount, hasMore } = this.props;
const isMoreFollows = ['followers', 'following'].some(k => k === scrollKey);
if (!(diffCount && isMoreFollows)) return null;
if (hasMore) return null;
return (
<MoreFollows visible={!isLoading} count={diffCount} type={scrollKey} />