Skip to content

Commit 10a1d4d

Browse files
authored
fix: should_add_reactions returning true for Button menu (#33)
1 parent d57fb24 commit 10a1d4d

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

nextcord/ext/menus/menu_pages.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,13 +65,10 @@ async def change_source(self, source: PageSource):
6565
await self.show_page(0)
6666

6767
def should_add_reactions(self) -> bool:
68-
return self.should_add_reactions_or_buttons()
68+
return super().should_add_reactions() and self._source.is_paginating()
6969

7070
def should_add_buttons(self) -> bool:
71-
return self.should_add_reactions_or_buttons()
72-
73-
def should_add_reactions_or_buttons(self) -> bool:
74-
return self._source.is_paginating()
71+
return super().should_add_buttons() and self._source.is_paginating()
7572

7673
async def _get_kwargs_from_page(self, page: List[Any]) -> SendKwargsType:
7774
"""|coro|
@@ -324,6 +321,9 @@ def __init__(
324321
# disable buttons that are not available
325322
self._disable_unavailable_buttons()
326323

324+
def should_add_buttons(self) -> bool:
325+
return self._source.is_paginating()
326+
327327
async def show_page(self, page_number: int):
328328
"""|coro|
329329
Sets the current page to the specified page and shows it.

0 commit comments

Comments
 (0)