Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIlya Zverev <zverik@textual.ru>2017-03-20 15:51:59 +0300
committerSergey Yershov <syershov@maps.me>2017-03-20 16:36:09 +0300
commit42ceabc905dae250643079ad8b3ce6e35eea06ca (patch)
treed85b7c099786021e620e082f36d928bc638b3bde /tools/python
parent0010540f224a815632a991b58c6165e75603fbf6 (diff)
[build] Fix cmake in build_omim and error detection in booking_hotels
Diffstat (limited to 'tools/python')
-rwxr-xr-xtools/python/booking_hotels.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/python/booking_hotels.py b/tools/python/booking_hotels.py
index ef58443180..20950706af 100755
--- a/tools/python/booking_hotels.py
+++ b/tools/python/booking_hotels.py
@@ -60,7 +60,7 @@ class BookingApi:
stream = urllib2.urlopen(request)
payload = stream.read()
data = json.loads(payload)
- if isinstance(data, dict) and 'ruid' in data:
+ if isinstance(data, dict) and 'message' in data and 'code' in data:
logging.error('Api call failed with error: {0} Code: {1}'.format(data['message'], data['code']))
return None
return data