Skip to content

Commit 4bdd5d5

Browse files
committedApr 21, 2022
fix: normalize win32 paths before globbing
1 parent 18666fc commit 4bdd5d5

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed
 

‎lib/verify.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ const path = require('path')
1313
const rimraf = util.promisify(require('rimraf'))
1414
const ssri = require('ssri')
1515

16+
const globify = pattern => pattern.split('\\').join('/')
17+
1618
const hasOwnProperty = (obj, key) =>
1719
Object.prototype.hasOwnProperty.call(obj, key)
1820

@@ -119,7 +121,7 @@ function garbageCollect (cache, opts) {
119121
indexStream.on('end', resolve).on('error', reject)
120122
}).then(() => {
121123
const contentDir = contentPath.contentDir(cache)
122-
return glob(path.join(contentDir, '**'), {
124+
return glob(globify(path.join(contentDir, '**')), {
123125
follow: false,
124126
nodir: true,
125127
nosort: true,

0 commit comments

Comments
 (0)
Please sign in to comment.