Skip to content
This repository has been archived by the owner on Dec 7, 2022. It is now read-only.

Commit

Permalink
Fix name of json key
Browse files Browse the repository at this point in the history
  • Loading branch information
jackshendrikov committed Apr 23, 2021
1 parent c5457af commit 2216064
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ip_locator/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ def analyze_api(data_apis):
keys2_replace = ['city', 'regionName', 'lat', 'lon', 'isp', 'timezone']

if (data_apis[0]['country'] == data_apis[1]['country'] and data_apis[0]['city'] == data_apis[1]['city']) \
or (data_apis[0]['country'] == data_apis[2]['country'] and data_apis[0]['city'] == data_apis[2]['city']):
or (data_apis[0]['country'] == data_apis[2]['country_name'] and data_apis[0]['city'] == data_apis[2]['city']):
# check equality of lng, lat from API1 and API3
if int(data_apis[0]['latitude']) == int(data_apis[2]['latitude']) \
and int(data_apis[0]['longitude']) == int(data_apis[2]['longitude']):
Expand Down

0 comments on commit 2216064

Please sign in to comment.