From f2194aab20be3008d7b9ea239d01dbcd05319736 Mon Sep 17 00:00:00 2001 From: Cyril Barillet Date: Tue, 2 Jun 2015 08:07:15 +0200 Subject: [PATCH] Fix regexp to catch (un)subscribe addresses --- index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/index.js b/index.js index 543e14e..3c91e86 100644 --- a/index.js +++ b/index.js @@ -8,7 +8,7 @@ db['dbSettings'].cache = 0; exports.registerRoute = function (hook_name, args, callback) { // Catching (un)subscribe addresses - args.app.get(/\/p/*/(un){0,1}subscribe=\/(.*)/, function(req, res) { + args.app.get(/\/p\/.*\/(un){0,1}subscribe=(.*)/, function(req, res) { var fullURL = req.protocol + "://" + req.get('host') + req.url; var path=req.url.split("/"); var padId=path[2];