only clear timelines on new profile

This commit is contained in:
FloatingGhost 2022-08-31 23:32:02 +01:00 committed by eris
parent 5be3326f22
commit a6051f49cf

View file

@ -103,10 +103,9 @@ const UserProfile = {
if (this.isUs) timelineTabMap['favorites'] = 'favorites' if (this.isUs) timelineTabMap['favorites'] = 'favorites'
const timeline = timelineTabMap[nextTab] const timeline = timelineTabMap[nextTab]
const lastTimeline = timelineTabMap[previousTab]
if (timeline) { if (timeline) {
this.stopFetching() this.stopFetching()
if (lastTimeline) this.$store.commit('clearTimeline', { timeline: lastTimeline })
this.$store.dispatch('startFetchingTimeline', { timeline: timeline, userId: this.userId }) this.$store.dispatch('startFetchingTimeline', { timeline: timeline, userId: this.userId })
} }
}, },