Skip to content

Commit d7ed9c1

Browse files
committed
fix(Environment): allow null value for protectConfig in EnvironmentJSON interface
1 parent e769ad5 commit d7ed9c1

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packages/clerk-js/src/core/resources/Environment.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ export class Environment extends BaseResource implements EnvironmentResource {
5555
this.userSettings = new UserSettings(data.user_settings);
5656
this.commerceSettings = new CommerceSettings(data.commerce_settings);
5757
this.apiKeysSettings = new APIKeySettings(data.api_keys_settings);
58-
this.protectConfig = new ProtectConfig(data.protect_config ?? null);
58+
this.protectConfig = new ProtectConfig(data.protect_config);
5959

6060
return this;
6161
}

packages/shared/src/types/json.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ export interface EnvironmentJSON extends ClerkResourceJSON {
9191
maintenance_mode: boolean;
9292
organization_settings: OrganizationSettingsJSON;
9393
user_settings: UserSettingsJSON;
94-
protect_config: ProtectConfigJSON;
94+
protect_config: ProtectConfigJSON | null;
9595
}
9696

9797
export type LastAuthenticationStrategy =

0 commit comments

Comments
 (0)