Revert "Handle subscriptions"

This reverts commit d3a761e729.
This commit is contained in:
M66B 2019-04-23 20:34:16 +02:00
parent 09e6357d0b
commit 6ea18cfe99
1 changed files with 1 additions and 11 deletions

View File

@ -704,12 +704,10 @@ class Core {
Map<String, List<EntityFolder>> parentFolders = new HashMap<>();
for (Folder ifolder : ifolders) {
String fullName = ifolder.getFullName();
boolean subscribed = ifolder.isSubscribed();
String[] attr = attrs.get(ifolder);
String type = EntityFolder.getType(attr, fullName);
EntityLog.log(context, account.name + ":" + fullName +
" subscribed=" + subscribed +
" attrs=" + TextUtils.join(" ", attr) + " type=" + type);
if (type != null) {
@ -726,7 +724,7 @@ class Core {
folder.name = fullName;
folder.display = display;
folder.type = (EntityFolder.SYSTEM.equals(type) ? type : EntityFolder.USER);
folder.synchronize = subscribed;
folder.synchronize = false;
folder.poll = ("imap.gmail.com".equals(account.host));
folder.sync_days = EntityFolder.DEFAULT_SYNC;
folder.keep_days = EntityFolder.DEFAULT_KEEP;
@ -735,14 +733,6 @@ class Core {
} else {
Log.i(folder.name + " exists type=" + folder.type);
if (folder.synchronize && !subscribed)
try {
Log.i(folder.name + " subscribe=" + folder.synchronize);
ifolder.setSubscribed(folder.synchronize);
} catch (MessagingException ex) {
Log.w(ex);
}
if (folder.display == null) {
if (display != null) {
db.folder().setFolderDisplay(folder.id, display);