From be237d076eb2287082b57bbb089ba1e62b447387 Mon Sep 17 00:00:00 2001 From: Juan Tejada Date: Fri, 31 Mar 2017 15:12:18 -0700 Subject: [PATCH] [client-app] Remove unecessary db setup for mail rules Summary: This shaves off ~150ms trying to issue this query Test Plan: manual Reviewers: evan, spang, mark Reviewed By: mark Differential Revision: https://phab.nylas.com/D4317 --- .../client-app/src/flux/stores/database-store.es6 | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/packages/client-app/src/flux/stores/database-store.es6 b/packages/client-app/src/flux/stores/database-store.es6 index daadb474a..2d715e408 100644 --- a/packages/client-app/src/flux/stores/database-store.es6 +++ b/packages/client-app/src/flux/stores/database-store.es6 @@ -212,17 +212,6 @@ class DatabaseStore extends NylasStore { } this._db.pragma(`user_version=${DatabaseVersion}`); - - const exportPath = path.join(NylasEnv.getConfigDirPath(), 'mail-rules-export.json') - if (fs.existsSync(exportPath)) { - try { - const row = JSON.parse(fs.readFileSync(exportPath)); - this.inTransaction(t => t.persistJSONBlob('MailRules-V2', row.json)); - fs.unlink(exportPath); - } catch (mailRulesError) { - console.log(`Could not re-import mail rules: ${mailRulesError}`); - } - } return ready(); }