From 65e89afc40a0840f1c03a1569b5d13501063011c Mon Sep 17 00:00:00 2001 From: Jesse Vincent Date: Tue, 18 Jan 2011 00:04:17 +0000 Subject: [PATCH] remove a duplicate codepath for folder insert --- src/com/fsck/k9/mail/store/LocalStore.java | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/src/com/fsck/k9/mail/store/LocalStore.java b/src/com/fsck/k9/mail/store/LocalStore.java index 5c943968a..3781dd558 100644 --- a/src/com/fsck/k9/mail/store/LocalStore.java +++ b/src/com/fsck/k9/mail/store/LocalStore.java @@ -1471,24 +1471,7 @@ public class LocalStore extends Store implements Serializable @Override public boolean create(FolderType type) throws MessagingException { - if (exists()) - { - throw new MessagingException("Folder " + mName + " already exists."); - } - database.execute(false, new DbCallback() - { - @Override - public Void doDbWork(final SQLiteDatabase db) throws WrappedException - { - db.execSQL("INSERT INTO folders (name, visible_limit) VALUES (?, ?)", new Object[] - { - mName, - mAccount.getDisplayCount() - }); - return null; - } - }); - return true; + return create(type, mAccount.getDisplayCount()); } @Override