Skip to content

Commit 6f5728a

Browse files
committed
Lazy require semver in getReleaseTag
1 parent 64c3ec1 commit 6f5728a

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

registry/lib/packages.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
'use strict'
22

3-
const semver = /*@__PURE__*/ require('../external/semver')
4-
53
const abortSignal = /*@__PURE__*/ require('./constants/abort-signal')
64
const copyLeftLicenses = /*@__PURE__*/ require('./constants/copy-left-licenses')
75
const LOOP_SENTINEL = /*@__PURE__*/ require('./constants/loop-sentinel')
@@ -706,6 +704,7 @@ function findTypesForSubpath(entryExports, subpath) {
706704

707705
/*@__NO_SIDE_EFFECTS__*/
708706
function getReleaseTag(version) {
707+
const semver = getSemver()
709708
return semver.prerelease(version)?.join('.') ?? 'latest'
710709
}
711710

0 commit comments

Comments
 (0)