Skip to content

Commit

Permalink
Remove unnecessary catch
Browse files Browse the repository at this point in the history
  • Loading branch information
joshdover committed Oct 5, 2020
1 parent 37ff0f1 commit 6d26685
Showing 1 changed file with 1 addition and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -158,17 +158,7 @@ export class UiActionsServiceEnhancements

private registerFeatureUsage = (definition: ActionFactoryDefinition<any, any, any>): void => {
if (!definition.minimalLicense || !definition.licenseFeatureName) return;

// Intentionally don't wait for response because
// happens in setup phase and has to be sync
this.deps.featureUsageSetup
.register(definition.licenseFeatureName, definition.minimalLicense)
.catch(() => {
// eslint-disable-next-line no-console
console.warn(
`ActionFactory [actionFactory.id = ${definition.id}] fail to register feature for featureUsage.`
);
});
this.deps.featureUsageSetup.register(definition.licenseFeatureName, definition.minimalLicense);
};

public readonly telemetry = (state: DynamicActionsState, telemetry: Record<string, any> = {}) => {
Expand Down

0 comments on commit 6d26685

Please sign in to comment.