mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-10-21 16:03:10 +00:00
Fix link buttons not being regarded as persistent
This commit is contained in:
@@ -217,6 +217,11 @@ class Button(Item[V]):
|
|||||||
def is_dispatchable(self) -> bool:
|
def is_dispatchable(self) -> bool:
|
||||||
return self.custom_id is not None
|
return self.custom_id is not None
|
||||||
|
|
||||||
|
def is_persistent(self) -> bool:
|
||||||
|
if self.style is ButtonStyle.link:
|
||||||
|
return self.url is not None
|
||||||
|
return super().is_persistent()
|
||||||
|
|
||||||
def refresh_component(self, button: ButtonComponent) -> None:
|
def refresh_component(self, button: ButtonComponent) -> None:
|
||||||
self._underlying = button
|
self._underlying = button
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user