WIP: Refactor Aurora (3.0.0) #29
1 changed files with 1 additions and 1 deletions
|
@ -277,7 +277,7 @@ class Change(AuroraBaseModel):
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def from_dict(cls, bot: Red, data: dict) -> "Change":
|
def from_dict(cls, bot: Red, data: dict) -> "Change":
|
||||||
logger.debug("Creating Change from dict: %s", data)
|
logger.debug("Creating Change from dict (%s): %s", type(data), data)
|
||||||
if "duration" in data and data["duration"] and not isinstance(data["duration"], timedelta):
|
if "duration" in data and data["duration"] and not isinstance(data["duration"], timedelta):
|
||||||
hours, minutes, seconds = map(int, data["duration"].split(':'))
|
hours, minutes, seconds = map(int, data["duration"].split(':'))
|
||||||
duration = timedelta(hours=hours, minutes=minutes, seconds=seconds)
|
duration = timedelta(hours=hours, minutes=minutes, seconds=seconds)
|
||||||
|
|
Loading…
Reference in a new issue