Skip to content

Commit

Permalink
Use f-string
Browse files Browse the repository at this point in the history
  • Loading branch information
blag committed Sep 19, 2023
1 parent 2584199 commit f8c5683
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion user_sessions/templatetags/user_sessions.py
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ def location(value):
location = None
if location and location['country_name']:
if 'city' in location and location['city']:
return '{}, {}'.format(location['city'], location['country_name'])
return f"{location['city']}, {location['country_name']}"
return location['country_name']
return None

Expand Down

0 comments on commit f8c5683

Please sign in to comment.