fix(edit) wrong file name on win

This commit is contained in:
coderaiser 2014-11-21 04:15:42 -05:00
parent 06c39ecd5d
commit b9d1249ec8

View file

@ -9,7 +9,8 @@
CloudFunc = require(DIR_LIB + 'cloudfunc'),
patch = require(DIR_SERVER + 'patch'),
files = require(DIR_SERVER + 'files'),
hash = require(DIR_SERVER + 'hash');
hash = require(DIR_SERVER + 'hash'),
mellow = require(DIR_SERVER + 'mellow');
module.exports = function(sock) {
Util.check(arguments, ['socket']);
@ -21,6 +22,8 @@
size: CloudFunc.MAX_FILE_SIZE
};
name = mellow.convertPath(name);
getHash(name, function(error, hash) {
if (error)
socket.emit('err', error);