Skip to content

Commit

Permalink
rename: has_enterprise_sso -> matches_sso_connection
Browse files Browse the repository at this point in the history
  • Loading branch information
NicolasLopes7 committed Dec 17, 2024
1 parent 7af6443 commit c5c216d
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions packages/clerk-js/src/core/resources/EmailAddress.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import { BaseResource, IdentificationLink, Verification } from './internal';
export class EmailAddress extends BaseResource implements EmailAddressResource {
id!: string;
emailAddress = '';
hasEnterpriseSso = false;
matchesSsoConnection = false;
linkedTo: IdentificationLinkResource[] = [];
verification!: VerificationResource;

Expand Down Expand Up @@ -132,7 +132,7 @@ export class EmailAddress extends BaseResource implements EmailAddressResource {
this.id = data.id;
this.emailAddress = data.email_address;
this.verification = new Verification(data.verification);
this.hasEnterpriseSso = data.has_enterprise_sso;
this.matchesSsoConnection = data.matches_sso_connection;
this.linkedTo = (data.linked_to || []).map(link => new IdentificationLink(link));
return this;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ const getEmailAddressVerificationStrategy = (
emailAddress: EmailAddressResource | undefined,
env: EnvironmentResource,
): PrepareEmailAddressVerificationParams['strategy'] => {
if (emailAddress?.hasEnterpriseSso) {
if (emailAddress?.matchesSsoConnection) {
return 'enterprise_sso';
}

Expand Down
2 changes: 1 addition & 1 deletion packages/types/src/emailAddress.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export interface EmailAddressResource extends ClerkResource {
id: string;
emailAddress: string;
verification: VerificationResource;
hasEnterpriseSso: boolean;
matchesSsoConnection: boolean;
linkedTo: IdentificationLinkResource[];
toString: () => string;
prepareVerification: (params: PrepareEmailAddressVerificationParams) => Promise<EmailAddressResource>;
Expand Down
2 changes: 1 addition & 1 deletion packages/types/src/json.ts
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ export interface EmailAddressJSON extends ClerkResourceJSON {
email_address: string;
verification: VerificationJSON | null;
linked_to: IdentificationLinkJSON[];
has_enterprise_sso: boolean;
matches_sso_connection: boolean;
}

export interface IdentificationLinkJSON extends ClerkResourceJSON {
Expand Down

0 comments on commit c5c216d

Please sign in to comment.