File tree Expand file tree Collapse file tree 2 files changed +3
-6
lines changed
apps/iframe-app/src/hooks Expand file tree Collapse file tree 2 files changed +3
-6
lines changed Original file line number Diff line number Diff line change @@ -58,7 +58,7 @@ describe('useAgentCard', () => {
5858 expect ( result . current . data ) . toEqual ( mockAgentCard ) ;
5959 expect ( mockFetch ) . toHaveBeenCalledWith (
6060 'https://api.example.com/.well-known/agent-card.json' ,
61- expect . objectContaining ( { credentials : 'include' , redirect : 'manual' } )
61+ expect . objectContaining ( { credentials : 'include' } )
6262 ) ;
6363 } ) ;
6464
@@ -104,7 +104,6 @@ describe('useAgentCard', () => {
104104 headers : expect . objectContaining ( {
105105 'X-API-Key' : 'test-api-key' ,
106106 } ) ,
107- redirect : 'manual' ,
108107 } )
109108 ) ;
110109 } ) ;
@@ -299,7 +298,6 @@ describe('useAgentCard', () => {
299298 expect . any ( String ) ,
300299 expect . objectContaining ( {
301300 credentials : 'include' ,
302- redirect : 'manual' ,
303301 } )
304302 ) ;
305303 } ) ;
Original file line number Diff line number Diff line change @@ -35,12 +35,11 @@ async function fetchAgentCard(config: UseAgentCardConfig): Promise<AgentCard> {
3535 requestInit . credentials = 'include' ;
3636 }
3737
38- requestInit . redirect = 'manual' ;
39-
4038 let response : Response ;
4139 try {
4240 response = await fetch ( url , requestInit ) ;
43- } catch {
41+ } catch ( er ) {
42+ console . log ( 'charlie error:' , er ) ;
4443 // Network error or CORS failure (e.g., EasyAuth 302 redirect to login page)
4544 return handleUnauthorized ( config ) ;
4645 }
You can’t perform that action at this time.
0 commit comments