zip-stream
Advanced tools
Comparing version 0.3.2 to 0.3.3
@@ -88,12 +88,2 @@ /** | ||
self.write(headers.encode('file', data)); | ||
function onend() { | ||
self.write(headers.encode('fileDescriptor', data)); | ||
self._afterAppend(data); | ||
callback(null, data); | ||
} | ||
if (data.store) { | ||
@@ -103,6 +93,12 @@ data.uncompressedSize = source.length; | ||
data.crc32 = crc32.unsigned(source); | ||
} else { | ||
data.flags |= (1 << 3); | ||
} | ||
self.write(headers.encode('file', data)); | ||
if (data.store) { | ||
self.write(source); | ||
onend(); | ||
self._afterAppend(data); | ||
callback(null, data); | ||
} else { | ||
@@ -118,3 +114,5 @@ var processStream = self._newProcessStream(data.store, function(err) { | ||
onend(); | ||
self.write(headers.encode('fileDescriptor', data)); | ||
self._afterAppend(data); | ||
callback(null, data); | ||
}); | ||
@@ -129,2 +127,3 @@ | ||
data.flags |= (1 << 3); | ||
data.offset = self.offset; | ||
@@ -206,3 +205,3 @@ | ||
data.flags = (1 << 3); | ||
data.flags = 0; | ||
data.compressionMethod = data.store ? 0 : 8; | ||
@@ -209,0 +208,0 @@ data.uncompressedSize = 0; |
{ | ||
"name": "zip-stream", | ||
"version": "0.3.2", | ||
"version": "0.3.3", | ||
"description": "a streaming zip archive generator.", | ||
@@ -5,0 +5,0 @@ "homepage": "https://github.com/ctalkington/node-zip-stream", |
@@ -1,2 +0,2 @@ | ||
# zip-stream v0.3.2 [![Build Status](https://travis-ci.org/ctalkington/node-zip-stream.svg?branch=master)](https://travis-ci.org/ctalkington/node-zip-stream) | ||
# zip-stream v0.3.3 [![Build Status](https://travis-ci.org/ctalkington/node-zip-stream.svg?branch=master)](https://travis-ci.org/ctalkington/node-zip-stream) | ||
@@ -3,0 +3,0 @@ zip-stream is a streaming zip archive generator. It was built to be a successor to [zipstream](https://npmjs.org/package/zipstream). Dependencies are kept to a minimum through the use of many of node's built-in modules including the use of zlib module for compression. |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
27217
597