change timeline min/max id updating behavior to not get stuck with 20 wrong type of activities on fetch older.

This commit is contained in:
shpuld 2018-04-13 22:35:55 +03:00
parent dc0fd8177c
commit a0e7803e42
2 changed files with 28 additions and 119 deletions

View file

@ -30,7 +30,7 @@ const fetchAndUpdate = ({store, credentials, timeline = 'friends', older = false
return apiService.fetchTimeline(args)
.then((statuses) => {
if (!older && statuses.length >= 20) {
if (!older && statuses.length >= 20 && !timelineData.loading) {
store.dispatch('queueFlush', { timeline: timeline, id: timelineData.maxId })
}
update({store, statuses, timeline, showImmediately})