The time epoch defined in settings can now be 0 (different from None).

The convert_gametime contrib now has a simple function to return gametime with units.
This commit is contained in:
Vincent Le Goff 2017-02-13 20:14:09 -08:00 committed by Griatch
parent ee1fc0b648
commit 753bd35226
2 changed files with 21 additions and 1 deletions

View file

@ -81,7 +81,8 @@ def game_epoch():
Get the game epoch.
"""
return settings.TIME_GAME_EPOCH or server_epoch()
game_epoch = settings.TIME_GAME_EPOCH
return game_epoch if game_epoch is not None else server_epoch()
def gametime(absolute=False):