File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
controlplane/src/core/services Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -571,7 +571,10 @@ export default class Keycloak {
571571 // Cast the data to the expected type
572572 return data as ParsedOpenIdConfiguration ;
573573 } catch ( e : unknown ) {
574- if ( isAxiosError ( e ) ) {
574+ if ( isCancel ( e ) ) {
575+ // The user canceled the request
576+ throw new PublicError ( EnumStatusCode . ERR , 'Request cancelled by user' ) ;
577+ } else if ( isAxiosError ( e ) ) {
575578 let message : string ;
576579 switch ( e . code ) {
577580 case 'ECONNABORTED' : {
@@ -586,9 +589,6 @@ export default class Keycloak {
586589 }
587590
588591 throw new PublicError ( EnumStatusCode . ERR , message ) ;
589- } else if ( isCancel ( e ) ) {
590- // The user canceled the request
591- throw new PublicError ( EnumStatusCode . ERR , 'Request cancelled by user' ) ;
592592 }
593593
594594 throw e ;
You can’t perform that action at this time.
0 commit comments