Skip to content

Commit f4c5f0e

Browse files
XhmikosRlukekarrys
authored andcommitted
fix(arborist): fix unescaped periods (#4462)
1 parent 5b29666 commit f4c5f0e

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

workspaces/arborist/lib/arborist/reify.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -716,7 +716,7 @@ module.exports = cls => class Reifier extends cls {
716716
// Shrinkwrap and Node classes carefully, so for now, just treat
717717
// the default reg as the magical animal that it has been.
718718
return resolved && resolved
719-
.replace(/^https?:\/\/registry.npmjs.org\//, this.registry)
719+
.replace(/^https?:\/\/registry\.npmjs\.org\//, this.registry)
720720
}
721721

722722
// bundles are *sort of* like shrinkwraps, in that the branch is defined

workspaces/arborist/lib/shrinkwrap.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,8 @@ const swKeyOrder = [
8080
]
8181

8282
// used to rewrite from yarn registry to npm registry
83-
const yarnRegRe = /^https?:\/\/registry.yarnpkg.com\//
84-
const npmRegRe = /^https?:\/\/registry.npmjs.org\//
83+
const yarnRegRe = /^https?:\/\/registry\.yarnpkg\.com\//
84+
const npmRegRe = /^https?:\/\/registry\.npmjs\.org\//
8585

8686
// sometimes resolved: is weird or broken, or something npa can't handle
8787
const specFromResolved = resolved => {

0 commit comments

Comments
 (0)