Skip to content
This repository has been archived by the owner on Mar 30, 2023. It is now read-only.

Commit

Permalink
Workaround for Tweet.place not decoded #309
Browse files Browse the repository at this point in the history
  • Loading branch information
pielco11 committed Dec 10, 2018
1 parent 108a8f9 commit 5de7885
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion twint/storage/elasticsearch.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,9 @@ def Tweet(Tweet, config):
if _near:
j_data["_source"].update({"geo_near": _near})
if Tweet.place:
j_data["_source"].update({"geo_tweet": getLocation(Tweet.place)})
_t_place = getLocation(Tweet.place)
if _t_place:
j_data["_source"].update({"geo_tweet": getLocation(Tweet.place)})
actions.append(j_data)

es = Elasticsearch(config.Elasticsearch)
Expand Down

0 comments on commit 5de7885

Please sign in to comment.