mirror of
https://gitlab.com/PronounsPage/PronounsPage.git
synced 2025-09-24 05:05:20 -04:00
(trans) role "code" should also be allowed to see /admin/translations
This commit is contained in:
parent
2628f0f25c
commit
a98e9f00a1
@ -239,4 +239,4 @@
|
||||
"trigender": 0.5
|
||||
},
|
||||
"diff": {}
|
||||
}
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
<template>
|
||||
<Page wide>
|
||||
<NotFound v-if="!$isGranted('translations')" />
|
||||
<NotFound v-if="!$isGranted('translations') && !$isGranted('code')" />
|
||||
<div v-else>
|
||||
<p>
|
||||
<nuxt-link to="/admin">
|
||||
|
@ -51,7 +51,7 @@ router.post('/translations/propose', handleErrorAsync(async (req, res) => {
|
||||
}));
|
||||
|
||||
router.get('/translations/proposals', handleErrorAsync(async (req, res) => {
|
||||
if (!req.isGranted('translations')) {
|
||||
if (!req.isGranted('translations') && !req.isGranted('code')) {
|
||||
return res.status(401).json({ error: 'Unauthorised' });
|
||||
}
|
||||
|
||||
@ -135,7 +135,7 @@ router.post('/translations/proposals-done', handleErrorAsync(async (req, res) =>
|
||||
}));
|
||||
|
||||
router.get('/translations/contributors', handleErrorAsync(async (req, res) => {
|
||||
if (!req.isGranted('translations')) {
|
||||
if (!req.isGranted('translations') && !req.isGranted('code')) {
|
||||
return res.status(401).json({ error: 'Unauthorised' });
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user