Yuvipanda has submitted this change and it was merged.

Change subject: Ignore messages that start with /
......................................................................


Ignore messages that start with /

Change-Id: I81e91590ce7b84c4794b434f411cf0500800f564
---
M ircyall/web2redis.py
1 file changed, 2 insertions(+), 0 deletions(-)

Approvals:
  Yuvipanda: Verified; Looks good to me, approved



diff --git a/ircyall/web2redis.py b/ircyall/web2redis.py
index 8c1cc77..e6e256b 100644
--- a/ircyall/web2redis.py
+++ b/ircyall/web2redis.py
@@ -15,6 +15,8 @@
         return 'No channels found', 400
     if not 'token' in request.form:
         return 'No token found', 400
+    if message.startswith('/'):
+        return 'Message starts with /, not going to process', 400
     data = {
         'message': request.form['message'],
         'channels': request.form.getlist('channels')

-- 
To view, visit https://gerrit.wikimedia.org/r/180331
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I81e91590ce7b84c4794b434f411cf0500800f564
Gerrit-PatchSet: 1
Gerrit-Project: operations/software/ircyall
Gerrit-Branch: master
Gerrit-Owner: Yuvipanda <[email protected]>
Gerrit-Reviewer: Yuvipanda <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to