chore: Noteモデルの引数を変更

pull/107/head
yupix 10 months ago
parent da296e4369
commit feae71a738
No known key found for this signature in database
GPG Key ID: 2FF705F5C56D9C06

@ -77,8 +77,8 @@ class Header:
class NoteReaction(AbstractModel):
__slots__ = ("__reaction", "__client")
def __init__(self, reaction: INoteReaction, *, client: ClientManager):
self.__reaction: INoteReaction = reaction
def __init__(self, raw_reaction: INoteReaction, *, client: ClientManager):
self.__reaction: INoteReaction = raw_reaction
self.__client: ClientManager = client
@property
@ -208,8 +208,8 @@ class Note:
client: ClientManager
"""
def __init__(self, note: INote, client: ClientManager):
self.__raw_note: INote = note
def __init__(self, raw_note: INote, client: ClientManager):
self.__raw_note: INote = raw_note
self.__client: ClientManager = client
@property

@ -131,10 +131,7 @@ class NotificationNote(Notification):
@property
def note(self) -> Note:
return Note(
self.__notification["note"],
client=self.__client,
)
return Note(self.__notification["note"], client=self.__client)
class NotificationPollEnd(Notification):
@ -150,10 +147,7 @@ class NotificationPollEnd(Notification):
@property
def note(self) -> Note:
return Note(
self.__notification["note"],
client=self.__client,
)
return Note(self.__notification["note"], client=self.__client)
class NotificationReaction(Notification):

Loading…
Cancel
Save