minor changes

This commit is contained in:
coderaiser 2013-02-24 09:27:50 -05:00
parent e5d98811cf
commit 812a11d104

View file

@ -15,6 +15,7 @@
var main = global.cloudcmd.main,
Util = main.util,
CloudFunc = main.cloudfunc,
OK = 200,
Header = main.generateHeaders({
@ -83,11 +84,12 @@
lCmd = pParams.command,
lMethod = pParams.method;
if( Util.isContainStr(lCmd, 'fs') )
if( Util.isContainStr(lCmd, CloudFunc.FS) )
lResult = onFS({
request : pParams.request,
response: pParams.response,
method : lMethod
method : lMethod,
name : lCmd
});
if(lCmd[0] === '/'){
@ -111,10 +113,11 @@
function onFS(pParams){
var lResult,
lMethod = pParams.method;
lMethod = pParams.method,
lName = Util.removeStr(pParams.name, CloudFunc.FS);
switch(lMethod){
case 'GET':
var lName = pParams.request.url;
lResult = main.commander.getDirContent(lName, function(pError, pData){
if(!pError){
pParams.request.url += '.json';