allow mobile delete endpoint

This commit is contained in:
Ryan Tharp 2020-08-17 03:52:55 +00:00
parent 3436867dde
commit 3cee372d5c
1 changed files with 5 additions and 0 deletions

View File

@ -142,6 +142,11 @@ module.exports = (app, prefix) => {
ok = true;
}
// allow users to delete their own messages
if (req.method.toLowerCase() === 'delete' && req.path.match(/^\/channels\//i) && req.path.match(/\/messages\//i)) {
ok = true;
}
// GET /token is valid, if you're passing a token...
if (req.method.toLowerCase() === 'get' && req.path.match(/^\/token/i)) {
ok = true;