Browse Source

Fix slack handling so it works.

master
Chris Smith 5 years ago
parent
commit
64db7a404c
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      lineandsinker/services/slack.py

+ 2
- 2
lineandsinker/services/slack.py View File

@@ -9,8 +9,8 @@ class Slack(Service):
9 9
 
10 10
     def accept_hook(self, identifier, request):
11 11
         if request.content_type == "application/json":
12
-            content = request.json()
12
+            content = request.json
13 13
         else:
14
-            content = json.loads(request.get_data()["payload"])
14
+            content = json.loads(request.form["payload"])
15 15
 
16 16
         yield {"type": f"slack", "source": identifier, "text": content["text"]}

Loading…
Cancel
Save