Browse Source

[commands] Fix Paginator still allowing lines which are too long.

pull/350/merge
Max Kamps 9 years ago
committed by Rapptz
parent
commit
8f0d16629f
  1. 2
      discord/ext/commands/formatter.py

2
discord/ext/commands/formatter.py

@ -89,7 +89,7 @@ class Paginator:
RuntimeError
The line was too big for the current :attr:`max_size`.
"""
if len(line) >= self.max_size:
if len(line) > self.max_size - len(self.prefix) - 2:
raise RuntimeError('Line exceeds maximum page size %s' % (self.max_size))
if self._count + len(line) + 1 > self.max_size:

Loading…
Cancel
Save