1
0
mirror of https://github.com/instaloader/instaloader.git synced 2024-08-18 20:59:38 +02:00

Fix Post.location / --geotags (#1244)

Closes #1109.
This commit is contained in:
Arman Yeghiazaryan 2021-08-04 19:28:56 +04:00 committed by GitHub
parent 0372f7c8e8
commit ae39ab9893
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -553,8 +553,8 @@ class Post:
return None
location_id = int(loc['id'])
if any(k not in loc for k in ('name', 'slug', 'has_public_page', 'lat', 'lng')):
loc = self._context.get_json("explore/locations/{0}/".format(location_id),
params={'__a': 1})['graphql']['location']
loc.update(self._context.get_json("explore/locations/{0}/".format(location_id),
params={'__a': 1})['native_location_data']['location_info'])
self._location = PostLocation(location_id, loc['name'], loc['slug'], loc['has_public_page'],
loc['lat'], loc['lng'])
return self._location