diff options
| author | Henry Jameson <me@hjkos.com> | 2019-03-21 23:27:14 +0200 |
|---|---|---|
| committer | Henry Jameson <me@hjkos.com> | 2019-03-21 23:27:14 +0200 |
| commit | d6c62fa50f1992c109c60d03aa44f5ed3ee94284 (patch) | |
| tree | 61eca1cd1a830d80730b3597b9db836f621fd193 /src/components/conversation/conversation.js | |
| parent | ee94a6732aff8a4ab64ca885e07d53f58bfb4cb4 (diff) | |
minor UI improvements - keep current behavior of showing originating post initially
Diffstat (limited to 'src/components/conversation/conversation.js')
| -rw-r--r-- | src/components/conversation/conversation.js | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/components/conversation/conversation.js b/src/components/conversation/conversation.js index 32bab144..e543102a 100644 --- a/src/components/conversation/conversation.js +++ b/src/components/conversation/conversation.js @@ -37,6 +37,15 @@ const conversation = { status () { return this.statusoid }, + idsToShow () { + if (this.relevantIds.length > 0) { + return this.relevantIds + } else if (this.statusId) { + return [this.statusId] + } else { + return [] + } + }, statusId () { if (this.statusoid.retweeted_status) { return this.statusoid.retweeted_status.id @@ -50,7 +59,7 @@ const conversation = { } const statusesObject = this.$store.state.statuses.allStatusesObject - const conversation = this.relevantIds.reduce((acc, id) => { + const conversation = this.idsToShow.reduce((acc, id) => { acc.push(statusesObject[id]) return acc }, []) |
