migrations: ignore maildir when in folder layout

Otherwise we'd be tryhing to move the maildir into itself and error out.
This commit is contained in:
Martin Weinelt 2025-06-26 16:52:49 +02:00
parent c45b8a1253
commit b10c54606b
No known key found for this signature in database
GPG key ID: 87C1E9888F856759

View file

@ -53,6 +53,8 @@ def is_maildir_related(path: Path, layout: FolderLayout) -> bool:
if layout is FolderLayout.Default and path.name.startswith("."):
return True
if layout is FolderLayout.Folder:
if path.name in ["mail"]:
return False
return True
return False