Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(core): Allow license:clear command to be used for licenses that failed renewal #10665

Merged
merged 4 commits into from
Sep 5, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions packages/cli/src/commands/license/clear.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,12 @@ export class ClearLicenseCommand extends BaseCommand {
async run() {
this.logger.info('Clearing license from database.');

// Invoke shutdown() to force any floating entitlements to be released
const license = Container.get(License);
await license.init();
await license.shutdown();
// Attempt to invoke shutdown() to force any floating entitlements to be released
try {
const license = Container.get(License);
await license.init();
await license.shutdown();
} catch {}
csuermann marked this conversation as resolved.
Show resolved Hide resolved
netroy marked this conversation as resolved.
Show resolved Hide resolved

await Container.get(SettingsRepository).delete({
key: SETTINGS_LICENSE_CERT_KEY,
Expand Down
Loading