mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 18:55:26 +00:00
feature(cloudcmd, rest) add NOT_LOG
This commit is contained in:
parent
1c1c933a21
commit
54e68952d2
2 changed files with 6 additions and 4 deletions
|
|
@ -224,6 +224,7 @@
|
|||
|
||||
getContent(name, function(error, data, isFile) {
|
||||
var json,
|
||||
NOT_LOG = true,
|
||||
query = main.getQuery(request),
|
||||
isJSON = Util.isContainStr(query, 'json');
|
||||
|
||||
|
|
@ -235,7 +236,7 @@
|
|||
} else if (isJSON) {
|
||||
p.name +='.json';
|
||||
json = Util.stringifyJSON(data);
|
||||
main.sendResponse(p, json, true);
|
||||
main.sendResponse(p, json, NOT_LOG);
|
||||
} else
|
||||
readIndex(data, function(error, data) {
|
||||
p.name = INDEX_PATH;
|
||||
|
|
@ -243,7 +244,7 @@
|
|||
if (error)
|
||||
main.sendError(error);
|
||||
else
|
||||
main.sendResponse(p, data, true);
|
||||
main.sendResponse(p, data, NOT_LOG);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
|
|
|||
|
|
@ -132,7 +132,8 @@
|
|||
switch (p.request.method) {
|
||||
case 'GET':
|
||||
onFSGet(query, p.name, function(error, data, isFile) {
|
||||
var str;
|
||||
var str,
|
||||
NOT_LOG = true;
|
||||
|
||||
if (error)
|
||||
sendError(params, error);
|
||||
|
|
@ -141,7 +142,7 @@
|
|||
else {
|
||||
p.name += '.json';
|
||||
str = Util.stringifyJSON(data);
|
||||
sendResponse(p, str, true);
|
||||
sendResponse(p, str, NOT_LOG);
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue