add prettier

This commit is contained in:
Thomas Ruoff
2019-11-14 08:41:27 +01:00
parent 5d945c8f66
commit f4ccfe4429
4 changed files with 56 additions and 45 deletions

View File

@@ -4,14 +4,14 @@ const configPath = require('xdg').basedir.configPath('switchmon/config.json');
const defaults = {
postCmd: undefined,
profiles: {},
profiles: {}
};
let config = Object.assign({}, defaults);
try {
config = Object.assign(config, require(configPath));
} catch(err) {
} catch (err) {
if (err.code !== 'MODULE_NOT_FOUND') {
throw err;
}