fix(rest) onGET: json.parse

This commit is contained in:
coderaiser 2015-10-14 07:10:11 -04:00
parent 8414dcec9c
commit 960430c848

View file

@ -121,8 +121,7 @@
* @param pParams {method, body, requrest, response}
*/
function onGET(params, callback) {
var cmd, json,
p = params;
var cmd, p = params;
if (p.name[0] === '/')
cmd = p.name.replace('/', '');
@ -141,11 +140,9 @@
break;
default:
json = {
message: 'Error: command not found!'
};
callback(json);
callback({
message: 'Not Found'
});
break;
}
}