mirror of
				https://github.com/LonamiWebs/Telethon.git
				synced 2025-11-04 01:47:27 +03:00 
			
		
		
		
	Fix RequestIter.__next__ propagating StopAsyncIteration (#1117)
This commit is contained in:
		
							parent
							
								
									8429f9bd3c
								
							
						
					
					
						commit
						70e0d865a8
					
				| 
						 | 
				
			
			@ -81,7 +81,10 @@ class RequestIter(abc.ABC):
 | 
			
		|||
        return result
 | 
			
		||||
 | 
			
		||||
    def __next__(self):
 | 
			
		||||
        try:
 | 
			
		||||
            return self.client.loop.run_until_complete(self.__anext__())
 | 
			
		||||
        except StopAsyncIteration:
 | 
			
		||||
            raise StopIteration
 | 
			
		||||
 | 
			
		||||
    def __aiter__(self):
 | 
			
		||||
        self.buffer = None
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue
	
	Block a user