Skip to content

Commit

Permalink
style(pre-commit): auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
  • Loading branch information
pre-commit-ci[bot] committed Jan 30, 2024
1 parent 520d003 commit a43dc73
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions discord/iterators.py
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,9 @@ async def _retrieve_messages(self, retrieve: int) -> list[MessagePayload]:
"""Retrieve messages and update next parameters."""
raise NotImplementedError

async def _retrieve_messages_before_strategy(self, retrieve: int) -> list[MessagePayload]:
async def _retrieve_messages_before_strategy(
self, retrieve: int
) -> list[MessagePayload]:
"""Retrieve messages using before parameter."""
before = self.before.id if self.before else None
data: list[MessagePayload] = await self.logs_from(
Expand All @@ -382,7 +384,9 @@ async def _retrieve_messages_before_strategy(self, retrieve: int) -> list[Messag
self.before = Object(id=int(data[-1]["id"]))
return data

async def _retrieve_messages_after_strategy(self, retrieve: int) -> list[MessagePayload]:
async def _retrieve_messages_after_strategy(
self, retrieve: int
) -> list[MessagePayload]:
"""Retrieve messages using after parameter."""
after = self.after.id if self.after else None
data: list[MessagePayload] = await self.logs_from(
Expand All @@ -394,7 +398,9 @@ async def _retrieve_messages_after_strategy(self, retrieve: int) -> list[Message
self.after = Object(id=int(data[0]["id"]))
return data

async def _retrieve_messages_around_strategy(self, retrieve: int) -> list[MessagePayload]:
async def _retrieve_messages_around_strategy(
self, retrieve: int
) -> list[MessagePayload]:
"""Retrieve messages using around parameter."""
if self.around:
around = self.around.id if self.around else None
Expand Down

0 comments on commit a43dc73

Please sign in to comment.