Update key allowed characters

This commit is contained in:
Alan Grainger
2024-10-28 10:09:59 +01:00
parent 1d343fe9d2
commit 8e30b559a1
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -7,7 +7,7 @@ const app = express()
require('dotenv').config()
app.get('/share/:key', async (req, res) => {
if (req.params.key.match(/[^A-Za-z0-9-_]/)) {
if (req.params.key.match(/[^\w-]/)) {
// Invalid characters in the incoming URL
res.status(404).send()
} else {