aboutsummaryrefslogtreecommitdiff
path: root/cgi
diff options
context:
space:
mode:
authorLibravatar z411 2019-03-30 23:18:20 -0300
committerLibravatar z411 2019-03-30 23:18:44 -0300
commited6e405f8845b810daf442668ba6aca56057bb94 (patch)
tree73cad5fb80ee165678c354f74ccb304bf8f52d57 /cgi
parentb0217fa450e43286e1f0820195ad833bf97c2d98 (diff)
downloadweabot-ed6e405f8845b810daf442668ba6aca56057bb94.tar.gz
weabot-ed6e405f8845b810daf442668ba6aca56057bb94.tar.xz
weabot-ed6e405f8845b810daf442668ba6aca56057bb94.zip
Deshabilitar Discord hook si no hay URL configurado
Diffstat (limited to 'cgi')
-rw-r--r--cgi/post.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/cgi/post.py b/cgi/post.py
index d129715..9d6f9c2 100644
--- a/cgi/post.py
+++ b/cgi/post.py
@@ -1230,6 +1230,9 @@ def magic_ball():
return string
def discord_hook(post, url):
+ if not Settings.DISCORD_HOOK_URL:
+ return
+
import urllib2
import json