genPOI: code style fixes
E129 can suck me off. Get a better syntax, Python.
This commit is contained in:
parent
2b550fdf66
commit
0143ad63a6
|
@ -286,7 +286,9 @@ class PlayerDict(dict):
|
|||
pass
|
||||
|
||||
try:
|
||||
profile = json.loads(urllib.request.urlopen(UUID_LOOKUP_URL + sname).read().decode("utf-8"))
|
||||
profile = json.loads(
|
||||
urllib.request.urlopen(UUID_LOOKUP_URL + sname).read().decode("utf-8")
|
||||
)
|
||||
if 'name' in profile:
|
||||
profile['retrievedAt'] = time.mktime(time.localtime())
|
||||
PlayerDict.uuid_cache[sname] = profile
|
||||
|
@ -437,8 +439,8 @@ def create_marker_from_filter_result(poi, result):
|
|||
d["createInfoWindow"] = result['createInfoWindow']
|
||||
|
||||
# Polylines and polygons
|
||||
if ('polyline' in result and hasattr(result['polyline'], '__iter__')) or \
|
||||
'polygon' in result and hasattr(result['polygon'], '__iter__'):
|
||||
if (('polyline' in result and hasattr(result['polyline'], '__iter__')) or
|
||||
'polygon' in result and hasattr(result['polygon'], '__iter__')):
|
||||
# If the points form a line or closed shape
|
||||
d['isLine'] = 'polyline' in result
|
||||
# Collect points
|
||||
|
|
Loading…
Reference in New Issue