Merge "explicitly note sanitize_timestamp return condition"

This commit is contained in:
Jenkins 2017-07-24 19:54:28 +00:00 committed by Gerrit Code Review
commit 91e7483ed1
1 changed files with 4 additions and 1 deletions

View File

@ -138,7 +138,10 @@ def decimal_to_dt(dec):
def sanitize_timestamp(timestamp):
"""Return a naive utc datetime object."""
"""Return a naive utc datetime object.
:returns: a timezone unaware timestamp
"""
if not timestamp:
return timestamp
if not isinstance(timestamp, datetime.datetime):