@@ -801,8 +801,8 @@ export class Clerk implements ClerkInterface {
801801 this . assertComponentsReady ( this . #componentControls) ;
802802 if ( disabledOrganizationsFeature ( this , this . environment ) ) {
803803 if ( this . #instanceType === 'development' ) {
804- throw new ClerkRuntimeError ( warnings . cannotRenderAnyOrganizationComponent ( 'OrganizationProfile' ) , {
805- code : CANNOT_RENDER_ORGANIZATIONS_DISABLED_ERROR_CODE ,
804+ this . __internal_openEnableOrganizations ( {
805+ callerName : 'OrganizationSwitcher' ,
806806 } ) ;
807807 }
808808 return ;
@@ -1044,8 +1044,8 @@ export class Clerk implements ClerkInterface {
10441044 this . assertComponentsReady ( this . #componentControls) ;
10451045 if ( disabledOrganizationsFeature ( this , this . environment ) ) {
10461046 if ( this . #instanceType === 'development' ) {
1047- throw new ClerkRuntimeError ( warnings . cannotRenderAnyOrganizationComponent ( 'OrganizationSwitcher' ) , {
1048- code : CANNOT_RENDER_ORGANIZATIONS_DISABLED_ERROR_CODE ,
1047+ this . __internal_openEnableOrganizations ( {
1048+ callerName : 'OrganizationSwitcher' ,
10491049 } ) ;
10501050 }
10511051 return ;
@@ -1083,8 +1083,8 @@ export class Clerk implements ClerkInterface {
10831083 this . assertComponentsReady ( this . #componentControls) ;
10841084 if ( disabledOrganizationsFeature ( this , this . environment ) ) {
10851085 if ( this . #instanceType === 'development' ) {
1086- throw new ClerkRuntimeError ( warnings . cannotRenderAnyOrganizationComponent ( 'OrganizationList' ) , {
1087- code : CANNOT_RENDER_ORGANIZATIONS_DISABLED_ERROR_CODE ,
1086+ this . __internal_openEnableOrganizations ( {
1087+ callerName : 'OrganizationSwitcher' ,
10881088 } ) ;
10891089 }
10901090 return ;
@@ -1270,8 +1270,8 @@ export class Clerk implements ClerkInterface {
12701270
12711271 if ( disabledOrganizationsFeature ( this , this . environment ) ) {
12721272 if ( this . #instanceType === 'development' ) {
1273- throw new ClerkRuntimeError ( warnings . cannotRenderAnyOrganizationComponent ( 'TaskChooseOrganization' ) , {
1274- code : CANNOT_RENDER_ORGANIZATIONS_DISABLED_ERROR_CODE ,
1273+ this . __internal_openEnableOrganizations ( {
1274+ callerName : 'OrganizationSwitcher' ,
12751275 } ) ;
12761276 }
12771277 return ;
0 commit comments