File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -493,14 +493,16 @@ class SocketSdk {
493493 }
494494
495495 /**
496- * @param {{[key: string]: boolean } } queryParams
496+ * @param {{[key: string]: string } } queryParams
497497 * @param {{components: {purl: string}[] } } components
498498 * @returns {Promise<SocketSdkResultType<'batchPackageFetch'>> }
499499 */
500500 async batchPackageFetch ( queryParams , components ) {
501+ const formattedQueryParam = new URLSearchParams ( queryParams )
502+
501503 try {
502504 const client = await this . #getClient( )
503- const data = await client . post ( `purl?${ queryParams } ` , { json : components } ) . json ( )
505+ const data = await client . post ( `purl?${ formattedQueryParam } ` , { json : components } ) . json ( )
504506 return { success : true , status : 200 , data }
505507 } catch ( err ) {
506508 return /** @type {SocketSdkErrorType<'batchPackageFetch'> } */ ( this . #handleApiError( err ) )
You can’t perform that action at this time.
0 commit comments