Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed SPECIAL-USE capability check #533

Merged
merged 1 commit into from
Aug 27, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions imapclient/imapclient.py
Original file line number Diff line number Diff line change
Expand Up @@ -757,10 +757,9 @@ def find_special_folder(self, folder_flag):
"""
# Detect folder by looking for known attributes
# TODO: avoid listing all folders by using extended LIST (RFC6154)
if self.has_capability("SPECIAL-USE"):
for folder in self.list_folders():
if folder and len(folder[0]) > 0 and folder_flag in folder[0]:
return folder[2]
for folder in self.list_folders():
if folder and len(folder[0]) > 0 and folder_flag in folder[0]:
return folder[2]

# Detect folder by looking for common names
# We only look for folders in the "personal" namespace of the user
Expand Down