skipper-disk
Advanced tools
Comparing version 0.5.7 to 0.5.8
{ | ||
"name": "skipper-disk", | ||
"version": "0.5.7", | ||
"version": "0.5.8", | ||
"description": "Receive Skipper's file uploads on your local filesystem", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -119,5 +119,14 @@ /** | ||
var file = _.find(receiver__._files, {fd: __newFile.fd}); | ||
// Set the byteCount of the stream to the "total" value of the file, which has | ||
// been updated as the file was written. | ||
__newFile.byteCount = file.total; | ||
if (file) { | ||
// Set the byteCount of the stream to the "total" value of the file, which has | ||
// been updated as the file was written. | ||
__newFile.byteCount = file.total; | ||
} | ||
// If we couldn't find the file in the receiver, that's super weird, but output | ||
// a notice and try to continue anyway. | ||
else { | ||
debug('Warning: received `finish` event for file `' + __newFile.fd + '`, but could not find a record of that file in the receiver.'); | ||
debug('Was this a zero-byte file?'); | ||
debug('Attempting to return the file anyway...'); | ||
} | ||
// Indicate that a file was persisted. | ||
@@ -124,0 +133,0 @@ receiver__.emit('writefile', __newFile); |
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
21184
302