Fix Alexa bug if no value for slots
This commit is contained in:
parent
bc4ab4d70a
commit
9876a2a081
2 changed files with 40 additions and 1 deletions
|
@ -116,7 +116,7 @@ class AlexaResponse(object):
|
|||
self.should_end_session = True
|
||||
if intent is not None and 'slots' in intent:
|
||||
self.variables = {key: value['value'] for key, value
|
||||
in intent['slots'].items()}
|
||||
in intent['slots'].items() if 'value' in value}
|
||||
else:
|
||||
self.variables = {}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue