mirror of
https://github.com/laurent22/joplin.git
synced 2026-06-18 20:16:34 +02:00
Handle command line args
This commit is contained in:
1 parent
2c713cdf7a
commit
01fc71d732
3 files changed
+58
-24
No files matched your search
@@ -113,14 +113,13 @@ class Setting extends BaseModel {
|
||||
let queries = [];
|
||||
queries.push('DELETE FROM settings');
|
||||
for (let i = 0; i < this.cache_.length; i++) {
|
||||
queries.push(Database.insertQuery(this.tableName(), this.cache_[i]));
|
||||
let s = Object.assign({}, this.cache_[i]);
|
||||
delete s.public;
|
||||
queries.push(Database.insertQuery(this.tableName(), s));
|
||||
}
|
||||
|
||||
return BaseModel.db().transactionExecBatch(queries).then(() => {
|
||||
this.logger().info('Settings have been saved.');
|
||||
}).catch((error) => {
|
||||
this.logger().error('Could not save settings');
|
||||
this.logger().error(error);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user