Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit fe29647

Browse files
authored
Merge pull request #13 from HarrisonGrodin/patch-1
Fix Python 3 compatibility
2 parents ac178f3 + 5607436 commit fe29647

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

app.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
A routing layer for the onboarding bot tutorial built using
44
[Slack's Events API](https://api.slack.com/events-api) in Python
55
"""
6-
import json
76
import bot
87
from flask import Flask, request, make_response, render_template
98

@@ -109,7 +108,7 @@ def hears():
109108
This route listens for incoming events from Slack and uses the event
110109
handler helper function to route events to our Bot.
111110
"""
112-
slack_event = json.loads(request.data)
111+
slack_event = request.get_json()
113112

114113
# ============= Slack URL Verification ============ #
115114
# In order to verify the url of our endpoint, Slack will send a challenge

0 commit comments

Comments
 (0)