Skip to content

Commit

Permalink
Fixed - updated_at timestamp reflects recent actions (#412)
Browse files Browse the repository at this point in the history
Looks good. I tested it and it seems to update the timestamp correctly when interacting with the API. I am curious if there are any other cases when we should be updating the timestamp.
  • Loading branch information
jahandaniyal committed Mar 20, 2021
1 parent 5f5f15a commit 0a3e7cd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion graphspace/mixins.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ class IDMixin(object):

class TimeStampMixin(object):
created_at = Column(TIMESTAMP, server_default=func.now(), nullable=False)
updated_at = Column(TIMESTAMP, server_default=func.now(), nullable=False)
updated_at = Column(TIMESTAMP, server_default=func.now(), nullable=False, onupdate=func.now())

0 comments on commit 0a3e7cd

Please sign in to comment.