fix: Clear favourites after destroy

This commit is contained in:
AkiraFukushima 2018-04-17 00:44:18 +09:00
parent d7b6ac7b7b
commit 14cabecaa3
1 changed files with 1 additions and 0 deletions

View File

@ -46,6 +46,7 @@ export default {
document.getElementById('scrollable').addEventListener('scroll', this.onScroll)
},
destroyed () {
this.$store.commit('TimelineSpace/Contents/Favourites/updateFavourites', [])
if (document.getElementById('scrollable') !== undefined && document.getElementById('scrollable') !== null) {
document.getElementById('scrollable').removeEventListener('scroll', this.onScroll)
}