mirror of
				https://github.com/LonamiWebs/Telethon.git
				synced 2025-11-04 01:47:27 +03:00 
			
		
		
		
	
							parent
							
								
									fb43f638ff
								
							
						
					
					
						commit
						2c85ffea12
					
				| 
						 | 
					@ -91,8 +91,9 @@ class _DialogsIter(RequestIter):
 | 
				
			||||||
                        cd.entity, 'migrated_to', None) is None:
 | 
					                        cd.entity, 'migrated_to', None) is None:
 | 
				
			||||||
                    self.buffer.append(cd)
 | 
					                    self.buffer.append(cd)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if len(r.dialogs) < self.request.limit\
 | 
					        if not self.buffer or len(r.dialogs) < self.request.limit\
 | 
				
			||||||
                or not isinstance(r, types.messages.DialogsSlice):
 | 
					                or not isinstance(r, types.messages.DialogsSlice):
 | 
				
			||||||
 | 
					            # Buffer being empty means all returned dialogs were skipped (due to offsets).
 | 
				
			||||||
            # Less than we requested means we reached the end, or
 | 
					            # Less than we requested means we reached the end, or
 | 
				
			||||||
            # we didn't get a DialogsSlice which means we got all.
 | 
					            # we didn't get a DialogsSlice which means we got all.
 | 
				
			||||||
            return True
 | 
					            return True
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue
	
	Block a user