Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/polls.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordartcafe <github@dartcafe.de>2021-01-10 23:28:11 +0300
committerdartcafe <github@dartcafe.de>2021-01-11 00:43:46 +0300
commit98feeb300ebd1a46c3bc4a9a7fd4c6d82a247d9b (patch)
tree1a8d91ee23e5c4e5c885e59d15ef993ca60270b2 /src/js/store/modules/subModules/shares.js
parentc8a5e72cdd7451347011b83a320ec21a8ce927b4 (diff)
refactoring, optimization, tidy
Signed-off-by: dartcafe <github@dartcafe.de>
Diffstat (limited to 'src/js/store/modules/subModules/shares.js')
-rw-r--r--src/js/store/modules/subModules/shares.js5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/js/store/modules/subModules/shares.js b/src/js/store/modules/subModules/shares.js
index ec52ea90..c2002827 100644
--- a/src/js/store/modules/subModules/shares.js
+++ b/src/js/store/modules/subModules/shares.js
@@ -98,20 +98,19 @@ const actions = {
context.commit('reset')
return
}
-
return axios.get(generateUrl(endPoint + '/shares'))
.then((response) => {
context.commit('set', response.data)
return response.data
})
.catch((error) => {
- console.error('Error loading shares', { error: error.response }, { pollId: context.rootState.poll.id })
+ console.error('Error loading shares', { error: error.response }, { pollId: context.rootState.route.params.id })
throw error
})
},
add(context, payload) {
- const endPoint = 'apps/polls/poll/' + context.rootState.poll.id
+ const endPoint = 'apps/polls/poll/' + context.rootState.route.params.id
return axios.post(generateUrl(endPoint + '/share'), payload.share)
.then((response) => {