Comparing version 3.1.0 to 3.1.1
@@ -6,3 +6,2 @@ import UrlInputError from "./error/url-input-error.js"; | ||
import { createFormattedStatus } from "../../transfer-visualize/format-transfer-status.js"; | ||
import InvalidContentLengthError from "./error/invalid-content-length-error.js"; | ||
import StatusCodeError from "../streams/download-engine-fetch-stream/errors/status-code-error.js"; | ||
@@ -102,10 +101,8 @@ const IGNORE_HEAD_STATUS_CODES = [405, 501, 404]; | ||
const downloadURL = newURL ?? part; | ||
if (acceptRange && isNaN(length)) { | ||
throw new InvalidContentLengthError(downloadURL); | ||
} | ||
downloadFile.totalSize += length || 0; | ||
const size = length || 0; | ||
downloadFile.totalSize += length; | ||
downloadFile.parts.push({ | ||
downloadURL, | ||
size: length || 0, | ||
acceptRange | ||
size, | ||
acceptRange: size > 0 && acceptRange | ||
}); | ||
@@ -112,0 +109,0 @@ if (counter++ === 0 && fileName) { |
{ | ||
"name": "ipull", | ||
"version": "3.1.0", | ||
"version": "3.1.1", | ||
"description": "The only file downloader you'll ever need. For node.js and the browser, CLI and library for fast and reliable file downloads.", | ||
@@ -5,0 +5,0 @@ "main": "dist/index.js", |
Sorry, the diff of this file is not supported yet
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
244666
3263