aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRapptz <[email protected]>2017-03-30 03:27:44 -0400
committerRapptz <[email protected]>2017-03-30 03:27:44 -0400
commitaf0ba17885774cc64070e0668be6d0c874adecf4 (patch)
tree4b204dd796881ac3d866f3bb6911b9f75f743dff
parentKeep track of Emoji instances myself. (diff)
downloaddiscord.py-af0ba17885774cc64070e0668be6d0c874adecf4.tar.xz
discord.py-af0ba17885774cc64070e0668be6d0c874adecf4.zip
Proper termination of HistoryIterator.flatten.
-rw-r--r--discord/iterators.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/discord/iterators.py b/discord/iterators.py
index 32489c90..c8a3bdc0 100644
--- a/discord/iterators.py
+++ b/discord/iterators.py
@@ -301,7 +301,7 @@ class HistoryIterator(_AsyncIterator):
self.channel = channel
while self._get_retrieve():
data = yield from self._retrieve_messages(self.retrieve)
- if self.limit is None and len(data) < 100:
+ if len(data) < 100:
self.limit = 0 # terminate the infinite loop
if self.reverse: