File tree Expand file tree Collapse file tree 5 files changed +5
-5
lines changed
Expand file tree Collapse file tree 5 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ export async function fileDownloadInfo(
5050 const resp = await ( params . fetch ?? fetch ) ( url , {
5151 method : "GET" ,
5252 headers : {
53- ...( params . credentials && {
53+ ...( accessToken && {
5454 Authorization : `Bearer ${ accessToken } ` ,
5555 } ) ,
5656 Range : "bytes=0-0" ,
Original file line number Diff line number Diff line change @@ -86,7 +86,7 @@ export async function* listDatasets<
8686 const res : Response = await ( params ?. fetch ?? fetch ) ( url , {
8787 headers : {
8888 accept : "application/json" ,
89- ...( params ?. credentials ? { Authorization : `Bearer ${ accessToken } ` } : undefined ) ,
89+ ...( accessToken ? { Authorization : `Bearer ${ accessToken } ` } : undefined ) ,
9090 } ,
9191 } ) ;
9292
Original file line number Diff line number Diff line change @@ -94,7 +94,7 @@ export async function* listModels<
9494 const res : Response = await ( params ?. fetch ?? fetch ) ( url , {
9595 headers : {
9696 accept : "application/json" ,
97- ...( params ?. credentials ? { Authorization : `Bearer ${ accessToken } ` } : undefined ) ,
97+ ...( accessToken ? { Authorization : `Bearer ${ accessToken } ` } : undefined ) ,
9898 } ,
9999 } ) ;
100100
Original file line number Diff line number Diff line change @@ -82,7 +82,7 @@ export async function* listSpaces<
8282 const res : Response = await ( params ?. fetch ?? fetch ) ( url , {
8383 headers : {
8484 accept : "application/json" ,
85- ...( params ?. credentials ? { Authorization : `Bearer ${ accessToken } ` } : undefined ) ,
85+ ...( accessToken ? { Authorization : `Bearer ${ accessToken } ` } : undefined ) ,
8686 } ,
8787 } ) ;
8888
Original file line number Diff line number Diff line change @@ -86,7 +86,7 @@ export async function pathsInfo(
8686 const resp = await ( params . fetch ?? fetch ) ( url , {
8787 method : "POST" ,
8888 headers : {
89- ...( params . credentials && {
89+ ...( accessToken && {
9090 Authorization : `Bearer ${ accessToken } ` ,
9191 } ) ,
9292 Accept : "application/json" ,
You can’t perform that action at this time.
0 commit comments