fix(aurora): remove empty lines in changes_factory and fix timestamp formatting
Some checks failed
Actions / Build Documentation (MkDocs) (pull_request) Successful in 28s
Actions / Lint Code (Ruff & Pylint) (pull_request) Failing after 41s

This commit is contained in:
cswimr 2024-08-19 17:50:52 -04:00
parent 709042f057
commit edbc950741
Signed by: cswimr
GPG key ID: 3813315477F26F82
2 changed files with 13 additions and 8 deletions

View file

@ -22,6 +22,12 @@ class Change(AuroraBaseModel):
def unix_timestamp(self) -> int:
return int(self.timestamp.timestamp())
@property
def unix_end_timestamp(self) -> Optional[int]:
if self.end_timestamp:
return int(self.end_timestamp.timestamp())
return None
def __str__(self):
return f"{self.type} {self.user_id} {self.reason}"