From 128563fad091fb8cb0a01bb5300ae7842c76f253 Mon Sep 17 00:00:00 2001 From: Wilfried Goesgens Date: Mon, 22 Dec 2014 20:14:47 +0100 Subject: [PATCH] since the template engine doesn't do this for you, we have to evaluate the subscribe command here too. --- webcit/listsub.c | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/webcit/listsub.c b/webcit/listsub.c index 5d9ceb8a7..64f809e52 100644 --- a/webcit/listsub.c +++ b/webcit/listsub.c @@ -24,7 +24,11 @@ int Conditional_LISTSUB_EXECUTE_SUBSCRIBE(StrBuf *Target, WCTemplputParams *TP) StrBuf *Line; const char *ImpMsg; const StrBuf *Room, *Email, *SubType; - + + if (strcmp(bstr("cmd"), "subscribe")) { + return 0; + } + Room = sbstr("room"); if (Room == NULL) { @@ -62,7 +66,11 @@ int Conditional_LISTSUB_EXECUTE_UNSUBSCRIBE(StrBuf *Target, WCTemplputParams *TP StrBuf *Line; const char *ImpMsg; const StrBuf *Room, *Email; - + + if (strcmp(bstr("cmd"), "unsubscribe")) { + return 0; + } + Room = sbstr("room"); if (Room == NULL) { @@ -98,7 +106,11 @@ int Conditional_LISTSUB_EXECUTE_CONFIRM_SUBSCRIBE(StrBuf *Target, WCTemplputPara StrBuf *Line; const char *ImpMsg; const StrBuf *Room, *Token; - + + if (strcmp(bstr("cmd"), "confirm")) { + return 0; + } + Room = sbstr("room"); if (Room == NULL) { -- 2.30.2