summaryrefslogtreecommitdiff
path: root/deps/npm/node_modules/cacache/lib/content/write.js
diff options
context:
space:
mode:
Diffstat (limited to 'deps/npm/node_modules/cacache/lib/content/write.js')
-rw-r--r--deps/npm/node_modules/cacache/lib/content/write.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/deps/npm/node_modules/cacache/lib/content/write.js b/deps/npm/node_modules/cacache/lib/content/write.js
index a79ae92902..c71363413c 100644
--- a/deps/npm/node_modules/cacache/lib/content/write.js
+++ b/deps/npm/node_modules/cacache/lib/content/write.js
@@ -28,7 +28,9 @@ function write (cache, data, opts) {
if (typeof opts.size === 'number' && data.length !== opts.size) {
return BB.reject(sizeError(opts.size, data.length))
}
- const sri = ssri.fromData(data, opts)
+ const sri = ssri.fromData(data, {
+ algorithms: opts.algorithms
+ })
if (opts.integrity && !ssri.checkData(data, opts.integrity, opts)) {
return BB.reject(checksumError(opts.integrity, sri))
}