mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-07-06 10:02:01 +00:00
[commands] Fix types for Bot.is_owner
This commit is contained in:
parent
13e102b6b9
commit
bfaee44b1f
@ -50,6 +50,7 @@ if TYPE_CHECKING:
|
|||||||
import importlib.machinery
|
import importlib.machinery
|
||||||
|
|
||||||
from discord.message import Message
|
from discord.message import Message
|
||||||
|
from discord.abc import User
|
||||||
from ._types import (
|
from ._types import (
|
||||||
Check,
|
Check,
|
||||||
CoroFunc,
|
CoroFunc,
|
||||||
@ -333,7 +334,7 @@ class BotBase(GroupMixin):
|
|||||||
# type-checker doesn't distinguish between functions and methods
|
# type-checker doesn't distinguish between functions and methods
|
||||||
return await discord.utils.async_all(f(ctx) for f in data) # type: ignore
|
return await discord.utils.async_all(f(ctx) for f in data) # type: ignore
|
||||||
|
|
||||||
async def is_owner(self, user: discord.User) -> bool:
|
async def is_owner(self, user: User) -> bool:
|
||||||
"""|coro|
|
"""|coro|
|
||||||
|
|
||||||
Checks if a :class:`~discord.User` or :class:`~discord.Member` is the owner of
|
Checks if a :class:`~discord.User` or :class:`~discord.Member` is the owner of
|
||||||
|
Loading…
x
Reference in New Issue
Block a user