Skip to content

Commit

Permalink
Fix matplotlib#5543: Handle timezone in num2date
Browse files Browse the repository at this point in the history
  • Loading branch information
fibersnet committed Nov 28, 2015
1 parent 6245d4e commit 3287080
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/matplotlib/dates.py
Expand Up @@ -281,7 +281,7 @@ def _from_ordinalf(x, tz=None):
elif dt.microsecond > 999990:
dt += datetime.timedelta(microseconds=1e6 - dt.microsecond)

return dt
return dt.astimezone(tz)


# a version of _from_ordinalf that can operate on numpy arrays
Expand Down

0 comments on commit 3287080

Please sign in to comment.