diff options
author | dartcafe <github@dartcafe.de> | 2021-10-29 23:33:26 +0300 |
---|---|---|
committer | dartcafe <github@dartcafe.de> | 2021-10-29 23:33:26 +0300 |
commit | 725fb75b244fde15c20c6a12ee63128ca9eba515 (patch) | |
tree | 76157159bebd3e108c0d850672965f6555cffb2b /src/js/mixins/watchPolls.js | |
parent | ecbf60a8fc1f78746616002dc0926b91b5e7bccb (diff) |
fix reactivity
Signed-off-by: dartcafe <github@dartcafe.de>
Diffstat (limited to 'src/js/mixins/watchPolls.js')
-rw-r--r-- | src/js/mixins/watchPolls.js | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/js/mixins/watchPolls.js b/src/js/mixins/watchPolls.js index 488e305f..a03bcad8 100644 --- a/src/js/mixins/watchPolls.js +++ b/src/js/mixins/watchPolls.js @@ -101,11 +101,11 @@ export const watchPolls = { dispatches = [...dispatches, 'poll/get'] } - if (this.loggedIn) { + if (this.isLoggedin) { // if user is an authorized user load polls list dispatches = [...dispatches, `${item.table}/list`] } - } else if (!this.loggedIn && (item.table === 'shares')) { + } else if (!this.isLoggedin && (item.table === 'shares')) { // if current user is guest and table is shares only reload current share dispatches = [...dispatches, 'share/get'] } else { @@ -113,7 +113,6 @@ export const watchPolls = { dispatches = [...dispatches, `${item.table}/list`] } }) - dispatches = [...new Set(dispatches)] // remove duplicates await Promise.all(dispatches.map((dispatches) => this.$store.dispatch(dispatches))) }, |