Skip to content

Commit

Permalink
Update sources/corepackUtils.ts
Browse files Browse the repository at this point in the history
replaceAll

Co-authored-by: Kristoffer K. <[email protected]>
  • Loading branch information
elrrrrrrr and merceyz authored Dec 6, 2023
1 parent 192b39d commit 4d7edbc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sources/corepackUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ export async function installVersion(installTarget: string, locator: Locator, {s
};
}

const defaultNpmRegistryURL = spec.url.replace(/\{\}/g, version);
const defaultNpmRegistryURL = spec.url.replaceAll(`{}`, version);
const url = process.env.COREPACK_NPM_REGISTRY ?
defaultNpmRegistryURL.replace(
npmRegistryUtils.DEFAULT_NPM_REGISTRY_URL,
Expand Down

0 comments on commit 4d7edbc

Please sign in to comment.