mirror of
				https://github.com/Rapptz/discord.py.git
				synced 2025-10-30 21:12:58 +00:00 
			
		
		
		
	Use a thread values view when constructing TextChannel.threads
Avoids an accidental O(n^2) situation.
This commit is contained in:
		| @@ -230,7 +230,7 @@ class TextChannel(discord.abc.Messageable, discord.abc.GuildChannel, Hashable): | ||||
|  | ||||
|         .. versionadded:: 2.0 | ||||
|         """ | ||||
|         return [thread for thread in self.guild.threads if thread.parent_id == self.id] | ||||
|         return [thread for thread in self.guild._threads.values() if thread.parent_id == self.id] | ||||
|  | ||||
|     def is_nsfw(self) -> bool: | ||||
|         """:class:`bool`: Checks if the channel is NSFW.""" | ||||
|   | ||||
		Reference in New Issue
	
	Block a user