Stark-Mountain / meetup-facebook-bot

An easy-to-setup bot that helps you to communicate with your meetup attendees.
MIT License
1 stars 1 forks source link

Refactor webhook() #23

Closed vergeev closed 7 years ago

vergeev commented 7 years ago

The body of for messaging_event in messaging_events loop can be factored out to a method named something like send_appropriate_response inside the message_processing module.

vergeev commented 7 years ago

The method should return the Facebook response to the request.

vergeev commented 7 years ago

Also, make the webhook() return 500 HTTP code if the send request didn't succeed with the send method name as a return string.

vergeev commented 7 years ago

Since #16 is closed, "refactoring" now also means "adding tests for the code".