Skip to content
This repository has been archived by the owner on Aug 22, 2019. It is now read-only.

Commit

Permalink
Merge pull request #1386 from m90/fix-format-output
Browse files Browse the repository at this point in the history
In `format_bot_output`, consider case where data key is present on dict, but None
  • Loading branch information
akelad committed Nov 23, 2018
2 parents 8b5f9dd + b5c279d commit c82d910
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion rasa_core/training/interactive.py
Original file line number Diff line number Diff line change
Expand Up @@ -241,8 +241,11 @@ def format_bot_output(

output = message.get("text") or ""

# Append all additional items
# Append all additional items if data is not None
data = message.get("data", {})
if not data:
return output

if data.get("image"):
output += "\nImage: " + data.get("image")

Expand Down

0 comments on commit c82d910

Please sign in to comment.