versione 1.2.14 :

- aggiornati i file di configurazione, ENV e script non funzionanti., package.
- corretto custom-service-worker.js con CORS
- ottimizzato il server, la chiamata Load iniziale (senza promise, con async/await).
This commit is contained in:
Surya Paolo
2025-03-12 21:03:02 +01:00
parent d106a59bb5
commit 7827e49760
19 changed files with 594 additions and 1549 deletions

View File

@@ -90,20 +90,19 @@ router.post('/', authenticate, async (req, res) => {
});
});
router.delete('/del', authenticate, (req, res) => {
router.delete('/del', authenticate, async (req, res) => {
// tools.mylog("TOKENREM = " + req.token);
try {
const browser = req.get('User-Agent');
Subscription.findOneAndDelete(
return await Subscription.findOneAndDelete(
{ userId: req.user._id, access: req.access, browser }).then(() => {
res.status(200).send();
}, () => {
res.status(400).send();
});
} catch (e) {
console.error('Err:', e.message);
}
});