feature(flop) add write

This commit is contained in:
coderaiser 2014-06-19 09:58:08 -04:00
parent 63cf7b8387
commit 9a6626aca6
4 changed files with 65 additions and 27 deletions

View file

@ -1,8 +1,7 @@
(function(){
'use strict';
var
DIR = '../../../',
var DIR = '../../../',
DIR_SERVER = DIR + 'server/',
Util = require(DIR + 'util'),
flop = require(DIR_SERVER + 'flop');

View file

@ -15,8 +15,7 @@
exports.onPut = onPut;
function onPut(name, query, readStream, callback) {
var options,
func = Util.exec.ret(callback),
var func = Util.exec.ret(callback),
baseName = path.basename(name);
switch(query) {
@ -33,11 +32,7 @@
break;
default:
options = {
gunzip : query === 'unzip'
};
pipe.create(readStream, name, options, function(error) {
flop.write(name, readStream, 'unzip', function(error) {
var msg;
if (!error)