mirror of
https://gitlab.com/PronounsPage/PronounsPage.git
synced 2025-09-26 14:32:04 -04:00
[admin][trans] shorter deduplication period for notifications
This commit is contained in:
parent
e59e4b06a3
commit
624e113b6a
@ -31,11 +31,11 @@ router.post('/translations/propose', handleErrorAsync(async (req, res) => {
|
||||
|
||||
if (req.isGranted('translations')) {
|
||||
for (let {email} of await findAdmins(req.db, global.config.locale, 'code')) {
|
||||
await deduplicateEmailPreset(req.db, email, 'translationToMerge', {locale: global.config.locale}, 60 * 60);
|
||||
await deduplicateEmailPreset(req.db, email, 'translationToMerge', {locale: global.config.locale});
|
||||
}
|
||||
} else {
|
||||
for (let {email} of await findAdmins(req.db, global.config.locale, 'translations')) {
|
||||
await deduplicateEmailPreset(req.db, email, 'translationProposed', {locale: global.config.locale}, 60 * 60);
|
||||
await deduplicateEmailPreset(req.db, email, 'translationProposed', {locale: global.config.locale});
|
||||
}
|
||||
}
|
||||
|
||||
@ -80,7 +80,7 @@ router.post('/translations/accept-proposal', handleErrorAsync(async (req, res) =
|
||||
await req.db.get(SQL`UPDATE translations SET status = ${TRANSLATION_STATUS.APPROVED} WHERE id = ${req.body.id}`)
|
||||
|
||||
for (let {email} of await findAdmins(req.db, global.config.locale, 'code')) {
|
||||
await deduplicateEmailPreset(req.db, email, 'translationToMerge', {locale: global.config.locale}, 60 * 60);
|
||||
await deduplicateEmailPreset(req.db, email, 'translationToMerge', {locale: global.config.locale});
|
||||
}
|
||||
|
||||
return res.json('OK');
|
||||
|
Loading…
x
Reference in New Issue
Block a user