mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 10:45:47 +00:00
refactor(config) patch
This commit is contained in:
parent
1c3d7438c1
commit
47ff924184
1 changed files with 9 additions and 10 deletions
|
|
@ -159,21 +159,20 @@ function patch(req, res, callback) {
|
|||
};
|
||||
|
||||
pullout(req, 'string', function(error, body) {
|
||||
var data = '',
|
||||
json = jonny.parse(body) || {};
|
||||
var json = jonny.parse(body) || {};
|
||||
|
||||
if (error)
|
||||
callback(error);
|
||||
else
|
||||
cryptoPass(json);
|
||||
|
||||
data = traverse(json);
|
||||
return callback(error);
|
||||
|
||||
cryptoPass(json);
|
||||
|
||||
save(function(error) {
|
||||
if (error)
|
||||
ponse.sendError(error, options);
|
||||
else
|
||||
ponse.send(data, options);
|
||||
return ponse.sendError(error, options);
|
||||
|
||||
var data = traverse(json);
|
||||
|
||||
ponse.send(data, options);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue