Fix retrieving a retoot's toot tree

This commit is contained in:
L. E. Segovia 2018-12-03 14:48:24 +00:00
parent 7fd49a95e4
commit 9ad4064504
No known key found for this signature in database
GPG Key ID: D5D1DC48B52B7AD5
1 changed files with 8 additions and 1 deletions

View File

@ -90,8 +90,15 @@ export default {
Event.$off('focus-sidebar')
},
methods: {
originalMessage (message) {
if (message.reblog !== null) {
return message.reblog
} else {
return message
}
},
load () {
this.$store.dispatch('TimelineSpace/Contents/SideBar/TootDetail/fetchToot', this.message)
this.$store.dispatch('TimelineSpace/Contents/SideBar/TootDetail/fetchToot', this.originalMessage(this.message))
.then(() => {
const toot = this.$refs.original
toot.scrollIntoView()