mirror of
https://github.com/jwinterm/modoboa.git
synced 2026-10-18 05:51:26 +02:00
fix(imap): issue when pattern is empty
Problem appear with some FTS backend Ref #2336
This commit is contained in:
@@ -301,7 +301,10 @@ class IMAPconnector:
|
||||
key = "SUBJECT"
|
||||
else:
|
||||
continue
|
||||
criterions = or_criterion(criterions, f'({key} "{pattern}")')
|
||||
if pattern:
|
||||
criterions = or_criterion(criterions, f'({key} "{pattern}")')
|
||||
else:
|
||||
criterions = "ALL"
|
||||
self.criterions = [bytearray(criterions, "utf8")]
|
||||
|
||||
def messages_count(self, **kwargs) -> int:
|
||||
|
||||
Reference in New Issue
Block a user