Fixed namespace errors

This commit is contained in:
M66B 2021-10-03 10:12:31 +02:00
parent 8e05ebff7b
commit 992374a9d9
1 changed files with 5 additions and 6 deletions

View File

@ -2031,26 +2031,25 @@ class Core {
List<Pair<Folder, Folder>> ifolders = new ArrayList<>();
List<String> subscription = new ArrayList<>();
boolean root = false;
List<Folder> personal = new ArrayList<>();
try {
Folder[] pnamespaces = istore.getPersonalNamespaces();
boolean root = false;
Folder d = istore.getDefaultFolder();
if (pnamespaces != null) {
personal.addAll(Arrays.asList(pnamespaces));
for (Folder p : pnamespaces)
if (d.getFullName().equals(p.getFullName())) {
if (defaultFolder.getFullName().equals(p.getFullName())) {
root = true;
break;
}
}
if (!root)
personal.add(d);
} catch (MessagingException ex) {
Log.e(ex);
}
if (!root)
personal.add(defaultFolder);
for (Folder namespace : personal) {
EntityLog.log(context, "Personal namespace=" + namespace.getFullName());