Skip to content

Commit

Permalink
User need to be in the annotation team to see shortcut
Browse files Browse the repository at this point in the history
  • Loading branch information
ddjnw1yu committed Sep 23, 2024
1 parent 266d92d commit 5672f67
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions pages/user/profile/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -350,9 +350,12 @@ export default {
"Cache-Control": "no-store"
}
let annotatorAuthenticated = false
const url = `${config.public.flatmap_api}annotator/authenticate?key=${mainStore.userToken}&session=`
annotatorAuthenticated = await $axios.get(url, { headers }).then(() => {
return true
const url = `${config.public.flatmap_api}/annotator/authenticate?key=${mainStore.userToken}`
annotatorAuthenticated = await $axios.get(url, { headers }).then((response) => {
if (response.data.data.canUpdate) {
return true
}
return false
}).catch(() => {
return false
})
Expand Down

0 comments on commit 5672f67

Please sign in to comment.