diff --git a/internal_packages/preferences/lib/tabs/preferences-general.jsx b/internal_packages/preferences/lib/tabs/preferences-general.jsx index 65367ee0c..877232580 100644 --- a/internal_packages/preferences/lib/tabs/preferences-general.jsx +++ b/internal_packages/preferences/lib/tabs/preferences-general.jsx @@ -1,7 +1,7 @@ /* eslint global-require: 0*/ import React from 'react'; -import fs from 'fs'; +import {Actions} from 'nylas-exports' import ConfigSchemaItem from './config-schema-item'; import WorkspaceSection from './workspace-section'; import SendingSection from './sending-section'; @@ -32,14 +32,9 @@ class PreferencesGeneral extends React.Component { } _resetEmailCache = () => { - const dataPath = `${NylasEnv.getConfigDirPath()}/edgehill.db` - fs.unlink(dataPath, (err) => { - if (err) console.log(err) - else this._reboot() - }) + Actions.resetEmailCache() } - render() { return (