mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-04-20 16:00:29 +00:00
Fix typehints for __class_getitem__ in Transform and Range
This commit is contained in:
parent
c115cfb0ac
commit
cf79af2dc4
@ -525,7 +525,7 @@ else:
|
||||
.. versionadded:: 2.0
|
||||
"""
|
||||
|
||||
def __class_getitem__(cls, items) -> _TransformMetadata:
|
||||
def __class_getitem__(cls, items) -> Transformer:
|
||||
if not isinstance(items, tuple):
|
||||
raise TypeError(f'expected tuple for arguments, received {items.__class__.__name__} instead')
|
||||
|
||||
@ -570,7 +570,7 @@ else:
|
||||
await interaction.response.send_message(f'Your value is {value}', ephemeral=True)
|
||||
"""
|
||||
|
||||
def __class_getitem__(cls, obj) -> _TransformMetadata:
|
||||
def __class_getitem__(cls, obj) -> RangeTransformer:
|
||||
if not isinstance(obj, tuple):
|
||||
raise TypeError(f'expected tuple for arguments, received {obj.__class__.__name__} instead')
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user