From 0406b3372d1f2fedf84d8b0e38e0bd3ac956ed56 Mon Sep 17 00:00:00 2001 From: Ryder Date: Sat, 20 Oct 2018 20:10:46 -0400 Subject: [PATCH] updating keys for airport name --- api/main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/api/main.py b/api/main.py index b4baa8a..ebd8e65 100644 --- a/api/main.py +++ b/api/main.py @@ -117,7 +117,7 @@ def _get_icao_code_from_dialogflow(request_dictionary): String|None -- The ICAO code string, or None """ try: - return request_dictionary['result']['parameters']['airport']['ICAO'] + return request_dictionary['queryResult']['parameters']['airport']['ICAO'] except KeyError as e: return None @@ -132,7 +132,7 @@ def _get_airport_name_from_dialogflow(request_dictionary): String|None -- The airport name string, or None """ try: - return request_dictionary['result']['parameters']['airport']['name'] + return request_dictionary['queryResult']['parameters']['airport']['name'] except KeyError as e: return None