split-file
Advanced tools
+2
-2
| { | ||
| "name": "split-file", | ||
| "version": "2.0.0", | ||
| "version": "2.1.0", | ||
| "private": false, | ||
@@ -20,3 +20,3 @@ "description": "Splitting and merging files with NodeJS", | ||
| "scripts": { | ||
| "test": "jest" | ||
| "test": "jest --runInBand" | ||
| }, | ||
@@ -23,0 +23,0 @@ "bin": { |
+5
-5
@@ -22,3 +22,3 @@ /*! | ||
| * @param {number} parts | ||
| * | ||
| * | ||
| * @returns {Promise} | ||
@@ -28,3 +28,3 @@ */ | ||
| var self = this; | ||
| // Validate parameters. | ||
@@ -98,3 +98,3 @@ if (parts < 1) { | ||
| // Number of parts (exclusive last part!) | ||
| var parts = Math.floor(totalSize / maxSize); | ||
| var parts = Math.ceil(totalSize / maxSize); | ||
| var splitSize = maxSize; | ||
@@ -125,3 +125,3 @@ | ||
| if (i === (parts - 1)) { | ||
| if (i === parts) { | ||
| partInfo[i].end = (i * splitSize) + lastSplitSize; | ||
@@ -170,3 +170,3 @@ } | ||
| * @param {object} partInfo | ||
| * | ||
| * | ||
| * @returns {Promise} | ||
@@ -173,0 +173,0 @@ */ |
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
12922
-0.01%