From c55c0107364cada95299b869d47ace80b87bdfdc Mon Sep 17 00:00:00 2001 From: Jonathan Kovarik Date: Mon, 28 Oct 2024 10:54:50 -0600 Subject: [PATCH] Fix bug in npm-tag --- bamboo/npm-tag.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bamboo/npm-tag.js b/bamboo/npm-tag.js index 525db3688ec..fa127d9544c 100644 --- a/bamboo/npm-tag.js +++ b/bamboo/npm-tag.js @@ -7,7 +7,6 @@ async function importGetLatestVersion() { const { default: getLatestVersion } = await import('latest-version'); return getLatestVersion; } -const getLatestVersion = await importGetLatestVersion(); const semver = require('semver'); // Given a git tag (process.env.GIT_TAG), this function determines what NPM @@ -30,6 +29,7 @@ const semver = require('semver'); // tagged "latest" in NPM then this is a new "latest" release, and "latest" is // returned. async function getNpmTag() { + const getLatestVersion = await importGetLatestVersion(); const thisTag = process.env.GIT_TAG; if (!thisTag) throw new Error('Version is not set');