php-imap
php-imap copied to clipboard
Fix - Query - Chunked - Resolved infinite loop when start chunk > 1
Resolved an issue when the start chunks value was > 1 an infinite loop would be created as handled messages would always be less than available messages.
Added more safety around input arguments, forcing minimums of 1 for both $chunk_size and $start_chunk.
Naturally the additional safety (minimums for arguments) might be a breaking change for some use cases, so that part is at the maintainers discretion. Absolutely happy to refactor if that is a problem :)
Hi @NeekTheNook , many thanks for your suggested improvements and your pull request!
Best regards & happy coding,