Replace render nothing: true with a JSON response. This has the added benefit of showing a “loading” message (#12)

render:nothing was producing an error 500 for some reason
This commit is contained in:
David Taylor 2017-11-27 08:08:19 +00:00 committed by Guo Xiang Tan
parent b69abe3913
commit 5f555849e5

View File

@ -98,7 +98,7 @@ module DiscourseChat::Provider::SlackProvider
json = JSON.parse(params[:payload], symbolize_names: true) json = JSON.parse(params[:payload], symbolize_names: true)
process_interactive(json) process_interactive(json)
render nothing: true, status: 200 render json: { text: I18n.t("chat_integration.provider.slack.transcript.loading") }
end end
def process_interactive(json) def process_interactive(json)