Skip to content

Commit e51bbcf

Browse files
committed
fix: license check in status tracker
1 parent b177e72 commit e51bbcf

File tree

1 file changed

+13
-2
lines changed

1 file changed

+13
-2
lines changed

src/utils/setup-status.ts

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,13 @@ import {
1313
} from "./configure-aws.ts";
1414
import { createEmitter } from "./emitter.ts";
1515
import { immediateOnce } from "./immediate-once.ts";
16-
import { checkIsLicenseValid, LICENSE_FILENAME } from "./license.ts";
16+
import {
17+
checkIsLicenseValid,
18+
activateLicense,
19+
LICENSE_FILENAME,
20+
} from "./license.ts";
1721
import type { UnwrapPromise } from "./promises.ts";
22+
import { minDelay } from "./promises.ts";
1823
import { checkSetupStatus } from "./setup.ts";
1924
import type { TimeTracker } from "./time-tracker.ts";
2025

@@ -277,6 +282,12 @@ function createLicenseStatusTracker(
277282
"[setup-status.license]",
278283
[LOCALSTACK_AUTH_FILENAME, LICENSE_FILENAME], //TODO rewrite to depend on change in localStackAuthenticationTracker
279284
async () =>
280-
(await checkIsLicenseValid(outputChannel)) ? "ok" : "setup_required",
285+
(await minDelay(
286+
activateLicense(outputChannel).then(() =>
287+
checkIsLicenseValid(outputChannel),
288+
),
289+
))
290+
? "ok"
291+
: "setup_required",
281292
);
282293
}

0 commit comments

Comments
 (0)