Extract query validation logic
This commit is contained in:
@@ -24,7 +24,7 @@ export class GlobalConfigRouter extends PromiseRouter {
|
||||
return acc;
|
||||
}, {});
|
||||
let database = req.config.database.WithoutValidation();
|
||||
return database.update('_GlobalConfig', {_id: 1}, update, {upsert: true}).then(() => {
|
||||
return database.update('_GlobalConfig', {objectId: 1}, update, {upsert: true}).then(() => {
|
||||
return Promise.resolve({ response: { result: true } });
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user