Skip to content

Commit

Permalink
chore: pyupgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
gforcada committed Apr 1, 2023
1 parent 674728e commit 781fea1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plone/app/discussion/comment.py
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ def __getattribute__(self, attr):
# In older versions of the add-on dates were set timezone naive.
# In tz aware versions, the value is stored as self._creation_date
if attr in ["creation_date", "modification_date"]:
old_date = super(Comment, self).__getattribute__(attr)
old_date = super().__getattribute__(attr)
if old_date.tzinfo is None:
# Naive dates were always stored utc
return old_date.replace(tzinfo=timezone.utc)
Expand Down

0 comments on commit 781fea1

Please sign in to comment.