feat(aurora): added an __int__
dunder method to the moderation model
This commit is contained in:
parent
38180f5ccd
commit
21fa3d9eb0
1 changed files with 3 additions and 0 deletions
|
@ -66,6 +66,9 @@ class Moderation(AuroraGuildModel):
|
|||
def __str__(self) -> str:
|
||||
return f"{self.moderation_type} {self.target_type} {self.target_id} {self.reason}"
|
||||
|
||||
def __int__(self) -> int:
|
||||
return self.moderation_id
|
||||
|
||||
async def resolve(self, resolved_by: int, reason: str) -> None:
|
||||
if self.resolved:
|
||||
raise ValueError("Case is already resolved!")
|
||||
|
|
Loading…
Reference in a new issue