mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-07-02 00:00:02 +00:00
Properly check for maximum number of children
This commit is contained in:
parent
9345a2a1be
commit
76666fbcf4
@ -320,7 +320,7 @@ class View:
|
|||||||
or the row the item is trying to be added to is full.
|
or the row the item is trying to be added to is full.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
if len(self._children) > 25:
|
if len(self._children) >= 25:
|
||||||
raise ValueError('maximum number of children exceeded')
|
raise ValueError('maximum number of children exceeded')
|
||||||
|
|
||||||
if not isinstance(item, Item):
|
if not isinstance(item, Item):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user