diff --git a/ui (gen4)/features/filesystem.js b/ui (gen4)/features/filesystem.js index 9cb0d5bf..ce3e793d 100755 --- a/ui (gen4)/features/filesystem.js +++ b/ui (gen4)/features/filesystem.js @@ -811,7 +811,9 @@ var FileSystemWriterActions = actions.Actions({ path = path || './exported' // resolve relative paths... - if(/^(\.\.?[\\\/]|[^\\\/])/.test(path)){ + if(/^(\.\.?[\\\/]|[^\\\/])/.test(path) + // and skip windows drives... + && !/^[a-z]:[\\\/]/i.test(path)){ // XXX do we need to normalize??? path = this.location.path +'/'+ path } @@ -910,9 +912,11 @@ var FileSystemWriterActions = actions.Actions({ var base_dir = this.location.path // resolve relative paths... - if(/^(\.\.?[\\\/]|[^\\\/])/.test(path)){ + if(/^(\.\.?[\\\/]|[^\\\/])/.test(path) + // and skip windows drives... + && !/^[a-z]:[\\\/]/i.test(path)){ // XXX do we need to normalize??? - path = base_dir +'/'+ path + path = this.location.path +'/'+ path } var to_dir = path diff --git a/ui (gen4)/file.js b/ui (gen4)/file.js index b70c424f..056a7ee6 100755 --- a/ui (gen4)/file.js +++ b/ui (gen4)/file.js @@ -103,12 +103,13 @@ function listJSON(path, pattern){ var denodeify = module.denodeify = function(func){ + var that = this return function(){ // XXX for some reason this does not see args2array... // XXX and for some reason the error is not reported... var args = [].slice.call(arguments) return new Promise(function(resolve, reject){ - func.apply(null, args.concat([function(err, res){ + func.apply(that, args.concat([function(err, res){ return err ? reject(err) : resolve(res) }])) })