diff options
| author | Moonman <shitposterclub@gmail.com> | 2019-05-20 15:23:36 -0400 |
|---|---|---|
| committer | Moonman <shitposterclub@gmail.com> | 2019-05-20 15:23:36 -0400 |
| commit | 0f824ff311bd3b1b8a0126ad9d7a2885440d3762 (patch) | |
| tree | d6fae83f6f4e3943c6034e927508a9482504d8b1 /src/components/status/status.js | |
| parent | f6600a35a5d3845ed6e7dc6cbbcd9494c7f9134f (diff) | |
switch from method to computed property
Diffstat (limited to 'src/components/status/status.js')
| -rw-r--r-- | src/components/status/status.js | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/src/components/status/status.js b/src/components/status/status.js index e2d2bb8b..ea4c2b9d 100644 --- a/src/components/status/status.js +++ b/src/components/status/status.js @@ -274,6 +274,9 @@ const Status = { }, ownStatus () { return this.status.user.id === this.$store.state.users.currentUser.id + }, + tags () { + return this.status.tags.filter(tagObj => tagObj.hasOwnProperty('name')).map(tagObj => tagObj.name).join(' ') } }, components: { @@ -289,13 +292,6 @@ const Status = { AvatarList }, methods: { - generateTagAttributes (tags) { - let res = {} - for (let tag of tags) { - res['data-tag-' + tag.name] = tag.name - } - return res - }, visibilityIcon (visibility) { switch (visibility) { case 'private': |
