Skip to content

Commit bf05c16

Browse files
committed
Don’t show ‘None’ as city
1 parent b483c7a commit bf05c16

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

user_sessions/templatetags/user_sessions.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ def location(value):
105105
warnings.warn(str(e))
106106
location = None
107107
if location and location['country_name']:
108-
if 'city' in location:
108+
if 'city' in location and location['city']:
109109
return '{}, {}'.format(location['city'], location['country_name'])
110110
return location['country_name']
111111
return None

0 commit comments

Comments
 (0)