WIP: Refactor Aurora (3.0.0) #29

Draft
cswimr wants to merge 347 commits from aurora-pydantic into main
Showing only changes of commit 5d53eec2f1 - Show all commits

View file

@ -53,10 +53,14 @@ class Change(AuroraBaseModel):
else:
timestamp = data["timestamp"]
try:
data["user_id"] = int(data["user_id"])
except ValueError:
data["user_id"] = 0
data.update({
"timestamp": timestamp,
"end_timestamp": end_timestamp,
"duration": duration,
"user_id": int(data["user_id"])
"duration": duration
})
return cls(bot=bot, **data)