From ba0fcadb6e42bd2652052c4e43f4b08d9b61c995 Mon Sep 17 00:00:00 2001 From: coderaiser Date: Tue, 8 Apr 2014 11:04:43 -0400 Subject: [PATCH] fix(rest) fse -> copy --- lib/server/rest.js | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/lib/server/rest.js b/lib/server/rest.js index 9fe49f1d..a74c67ef 100644 --- a/lib/server/rest.js +++ b/lib/server/rest.js @@ -36,14 +36,12 @@ NOT_LOG = true, - fse = main.srvrequire('ncp') || { - copy : function(from, to, callback) { - pipe.create({ - from : from, - to : to, - callback : callback - }); - } + copy = main.srvrequire('ncp') || function(from, to, callback) { + pipe.create({ + from : from, + to : to, + callback : callback + }); }; /** @@ -279,7 +277,7 @@ if (!Util.checkObjTrue(lFiles, ['from', 'to'])) sendError(pParams, p.data); else - fse.copy(lFiles.from, lFiles.to, function(error) { + copy(lFiles.from, lFiles.to, function(error) { if (error) sendError(pParams, error); else