From ed602405df8e4ddf9e7993e42eea9a5e9afd4856 Mon Sep 17 00:00:00 2001 From: Chris Lovering Date: Sat, 6 May 2023 20:09:19 +0100 Subject: Apply fixes for ruff linting --- pydis_core/utils/interactions.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'pydis_core/utils/interactions.py') diff --git a/pydis_core/utils/interactions.py b/pydis_core/utils/interactions.py index a6746e1e..6e419342 100644 --- a/pydis_core/utils/interactions.py +++ b/pydis_core/utils/interactions.py @@ -1,4 +1,5 @@ -from typing import Literal, Optional, Sequence +from collections.abc import Sequence +from typing import Literal from discord import ButtonStyle, HTTPException, Interaction, Message, NotFound, ui @@ -43,8 +44,8 @@ class ViewWithUserAndRoleCheck(ui.View): *, allowed_users: Sequence[int], allowed_roles: Sequence[int], - timeout: Optional[float] = 180.0, - message: Optional[Message] = None + timeout: float | None = 180.0, + message: Message | None = None ) -> None: super().__init__(timeout=timeout) self.allowed_users = allowed_users @@ -97,7 +98,7 @@ class DeleteMessageButton(ui.Button): style (:literal-url:`ButtonStyle `): The style of the button, set to ``ButtonStyle.secondary`` if not specified. label: The label of the button, set to "Delete" if not specified. - """ # noqa: E501 + """ def __init__( self, -- cgit v1.2.3