@@ -531,7 +531,6 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati
531
531
if ( configuration ) {
532
532
baseOptions = configuration . baseOptions ;
533
533
}
534
-
535
534
const localVarRequestOptions = { method : 'POST' , ...baseOptions , ...options } ;
536
535
const localVarHeaderParameter = { } as any ;
537
536
const localVarQueryParameter = { } as any ;
@@ -540,23 +539,18 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati
540
539
541
540
localVarHeaderParameter [ 'Content-Type' ] = 'application/json' ;
542
541
543
- const queryParameters = new URLSearchParams ( localVarUrlObj . search ) ;
542
+ const query = new URLSearchParams ( localVarUrlObj . search ) ;
544
543
for ( const key in localVarQueryParameter ) {
545
- queryParameters . set ( key , localVarQueryParameter [ key ] ) ;
544
+ query . set ( key , localVarQueryParameter [ key ] ) ;
546
545
}
547
546
for ( const key in options . query ) {
548
- queryParameters . set ( key , options . query [ key ] ) ;
547
+ query . set ( key , options . query [ key ] ) ;
549
548
}
550
- localVarUrlObj . search = ( new URLSearchParams ( queryParameters ) ) . toString ( ) ;
549
+ localVarUrlObj . search = ( new URLSearchParams ( query ) ) . toString ( ) ;
551
550
let headersFromBaseOptions = baseOptions && baseOptions . headers ? baseOptions . headers : { } ;
552
551
localVarRequestOptions . headers = { ...localVarHeaderParameter , ...headersFromBaseOptions , ...options . headers } ;
553
- const nonString = typeof deployContractSolidityBytecodeV1Request !== 'string' ;
554
- const needsSerialization = nonString && configuration && configuration . isJsonMime
555
- ? configuration . isJsonMime ( localVarRequestOptions . headers [ 'Content-Type' ] )
556
- : nonString ;
557
- localVarRequestOptions . data = needsSerialization
558
- ? JSON . stringify ( deployContractSolidityBytecodeV1Request !== undefined ? deployContractSolidityBytecodeV1Request : { } )
559
- : ( deployContractSolidityBytecodeV1Request || "" ) ;
552
+ const needsSerialization = ( typeof deployContractSolidityBytecodeV1Request !== "string" ) || localVarRequestOptions . headers [ 'Content-Type' ] === 'application/json' ;
553
+ localVarRequestOptions . data = needsSerialization ? JSON . stringify ( deployContractSolidityBytecodeV1Request !== undefined ? deployContractSolidityBytecodeV1Request : { } ) : ( deployContractSolidityBytecodeV1Request || "" ) ;
560
554
561
555
return {
562
556
url : localVarUrlObj . pathname + localVarUrlObj . search + localVarUrlObj . hash ,
@@ -578,7 +572,6 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati
578
572
if ( configuration ) {
579
573
baseOptions = configuration . baseOptions ;
580
574
}
581
-
582
575
const localVarRequestOptions = { method : 'POST' , ...baseOptions , ...options } ;
583
576
const localVarHeaderParameter = { } as any ;
584
577
const localVarQueryParameter = { } as any ;
@@ -587,23 +580,18 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati
587
580
588
581
localVarHeaderParameter [ 'Content-Type' ] = 'application/json' ;
589
582
590
- const queryParameters = new URLSearchParams ( localVarUrlObj . search ) ;
583
+ const query = new URLSearchParams ( localVarUrlObj . search ) ;
591
584
for ( const key in localVarQueryParameter ) {
592
- queryParameters . set ( key , localVarQueryParameter [ key ] ) ;
585
+ query . set ( key , localVarQueryParameter [ key ] ) ;
593
586
}
594
587
for ( const key in options . query ) {
595
- queryParameters . set ( key , options . query [ key ] ) ;
588
+ query . set ( key , options . query [ key ] ) ;
596
589
}
597
- localVarUrlObj . search = ( new URLSearchParams ( queryParameters ) ) . toString ( ) ;
590
+ localVarUrlObj . search = ( new URLSearchParams ( query ) ) . toString ( ) ;
598
591
let headersFromBaseOptions = baseOptions && baseOptions . headers ? baseOptions . headers : { } ;
599
592
localVarRequestOptions . headers = { ...localVarHeaderParameter , ...headersFromBaseOptions , ...options . headers } ;
600
- const nonString = typeof invokeContractV1Request !== 'string' ;
601
- const needsSerialization = nonString && configuration && configuration . isJsonMime
602
- ? configuration . isJsonMime ( localVarRequestOptions . headers [ 'Content-Type' ] )
603
- : nonString ;
604
- localVarRequestOptions . data = needsSerialization
605
- ? JSON . stringify ( invokeContractV1Request !== undefined ? invokeContractV1Request : { } )
606
- : ( invokeContractV1Request || "" ) ;
593
+ const needsSerialization = ( typeof invokeContractV1Request !== "string" ) || localVarRequestOptions . headers [ 'Content-Type' ] === 'application/json' ;
594
+ localVarRequestOptions . data = needsSerialization ? JSON . stringify ( invokeContractV1Request !== undefined ? invokeContractV1Request : { } ) : ( invokeContractV1Request || "" ) ;
607
595
608
596
return {
609
597
url : localVarUrlObj . pathname + localVarUrlObj . search + localVarUrlObj . hash ,
@@ -625,7 +613,6 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati
625
613
if ( configuration ) {
626
614
baseOptions = configuration . baseOptions ;
627
615
}
628
-
629
616
const localVarRequestOptions = { method : 'POST' , ...baseOptions , ...options } ;
630
617
const localVarHeaderParameter = { } as any ;
631
618
const localVarQueryParameter = { } as any ;
@@ -634,23 +621,18 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati
634
621
635
622
localVarHeaderParameter [ 'Content-Type' ] = 'application/json' ;
636
623
637
- const queryParameters = new URLSearchParams ( localVarUrlObj . search ) ;
624
+ const query = new URLSearchParams ( localVarUrlObj . search ) ;
638
625
for ( const key in localVarQueryParameter ) {
639
- queryParameters . set ( key , localVarQueryParameter [ key ] ) ;
626
+ query . set ( key , localVarQueryParameter [ key ] ) ;
640
627
}
641
628
for ( const key in options . query ) {
642
- queryParameters . set ( key , options . query [ key ] ) ;
629
+ query . set ( key , options . query [ key ] ) ;
643
630
}
644
- localVarUrlObj . search = ( new URLSearchParams ( queryParameters ) ) . toString ( ) ;
631
+ localVarUrlObj . search = ( new URLSearchParams ( query ) ) . toString ( ) ;
645
632
let headersFromBaseOptions = baseOptions && baseOptions . headers ? baseOptions . headers : { } ;
646
633
localVarRequestOptions . headers = { ...localVarHeaderParameter , ...headersFromBaseOptions , ...options . headers } ;
647
- const nonString = typeof runTransactionRequest !== 'string' ;
648
- const needsSerialization = nonString && configuration && configuration . isJsonMime
649
- ? configuration . isJsonMime ( localVarRequestOptions . headers [ 'Content-Type' ] )
650
- : nonString ;
651
- localVarRequestOptions . data = needsSerialization
652
- ? JSON . stringify ( runTransactionRequest !== undefined ? runTransactionRequest : { } )
653
- : ( runTransactionRequest || "" ) ;
634
+ const needsSerialization = ( typeof runTransactionRequest !== "string" ) || localVarRequestOptions . headers [ 'Content-Type' ] === 'application/json' ;
635
+ localVarRequestOptions . data = needsSerialization ? JSON . stringify ( runTransactionRequest !== undefined ? runTransactionRequest : { } ) : ( runTransactionRequest || "" ) ;
654
636
655
637
return {
656
638
url : localVarUrlObj . pathname + localVarUrlObj . search + localVarUrlObj . hash ,
@@ -676,7 +658,6 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati
676
658
if ( configuration ) {
677
659
baseOptions = configuration . baseOptions ;
678
660
}
679
-
680
661
const localVarRequestOptions = { method : 'POST' , ...baseOptions , ...options } ;
681
662
const localVarHeaderParameter = { } as any ;
682
663
const localVarQueryParameter = { } as any ;
@@ -685,23 +666,18 @@ export const DefaultApiAxiosParamCreator = function (configuration?: Configurati
685
666
686
667
localVarHeaderParameter [ 'Content-Type' ] = 'application/json' ;
687
668
688
- const queryParameters = new URLSearchParams ( localVarUrlObj . search ) ;
669
+ const query = new URLSearchParams ( localVarUrlObj . search ) ;
689
670
for ( const key in localVarQueryParameter ) {
690
- queryParameters . set ( key , localVarQueryParameter [ key ] ) ;
671
+ query . set ( key , localVarQueryParameter [ key ] ) ;
691
672
}
692
673
for ( const key in options . query ) {
693
- queryParameters . set ( key , options . query [ key ] ) ;
674
+ query . set ( key , options . query [ key ] ) ;
694
675
}
695
- localVarUrlObj . search = ( new URLSearchParams ( queryParameters ) ) . toString ( ) ;
676
+ localVarUrlObj . search = ( new URLSearchParams ( query ) ) . toString ( ) ;
696
677
let headersFromBaseOptions = baseOptions && baseOptions . headers ? baseOptions . headers : { } ;
697
678
localVarRequestOptions . headers = { ...localVarHeaderParameter , ...headersFromBaseOptions , ...options . headers } ;
698
- const nonString = typeof signTransactionRequest !== 'string' ;
699
- const needsSerialization = nonString && configuration && configuration . isJsonMime
700
- ? configuration . isJsonMime ( localVarRequestOptions . headers [ 'Content-Type' ] )
701
- : nonString ;
702
- localVarRequestOptions . data = needsSerialization
703
- ? JSON . stringify ( signTransactionRequest !== undefined ? signTransactionRequest : { } )
704
- : ( signTransactionRequest || "" ) ;
679
+ const needsSerialization = ( typeof signTransactionRequest !== "string" ) || localVarRequestOptions . headers [ 'Content-Type' ] === 'application/json' ;
680
+ localVarRequestOptions . data = needsSerialization ? JSON . stringify ( signTransactionRequest !== undefined ? signTransactionRequest : { } ) : ( signTransactionRequest || "" ) ;
705
681
706
682
return {
707
683
url : localVarUrlObj . pathname + localVarUrlObj . search + localVarUrlObj . hash ,
@@ -727,7 +703,7 @@ export const DefaultApiFp = function(configuration?: Configuration) {
727
703
async apiV1BesuDeployContractSolidityBytecode ( deployContractSolidityBytecodeV1Request ?: DeployContractSolidityBytecodeV1Request , options ?: any ) : Promise < ( axios ?: AxiosInstance , basePath ?: string ) => AxiosPromise < DeployContractSolidityBytecodeV1Response > > {
728
704
const localVarAxiosArgs = await DefaultApiAxiosParamCreator ( configuration ) . apiV1BesuDeployContractSolidityBytecode ( deployContractSolidityBytecodeV1Request , options ) ;
729
705
return ( axios : AxiosInstance = globalAxios , basePath : string = BASE_PATH ) => {
730
- const axiosRequestArgs = { ...localVarAxiosArgs . options , url : ( configuration ?. basePath || basePath ) + localVarAxiosArgs . url } ;
706
+ const axiosRequestArgs = { ...localVarAxiosArgs . options , url : basePath + localVarAxiosArgs . url } ;
731
707
return axios . request ( axiosRequestArgs ) ;
732
708
} ;
733
709
} ,
@@ -741,7 +717,7 @@ export const DefaultApiFp = function(configuration?: Configuration) {
741
717
async apiV1BesuInvokeContract ( invokeContractV1Request ?: InvokeContractV1Request , options ?: any ) : Promise < ( axios ?: AxiosInstance , basePath ?: string ) => AxiosPromise < InvokeContractV1Response > > {
742
718
const localVarAxiosArgs = await DefaultApiAxiosParamCreator ( configuration ) . apiV1BesuInvokeContract ( invokeContractV1Request , options ) ;
743
719
return ( axios : AxiosInstance = globalAxios , basePath : string = BASE_PATH ) => {
744
- const axiosRequestArgs = { ...localVarAxiosArgs . options , url : ( configuration ?. basePath || basePath ) + localVarAxiosArgs . url } ;
720
+ const axiosRequestArgs = { ...localVarAxiosArgs . options , url : basePath + localVarAxiosArgs . url } ;
745
721
return axios . request ( axiosRequestArgs ) ;
746
722
} ;
747
723
} ,
@@ -755,7 +731,7 @@ export const DefaultApiFp = function(configuration?: Configuration) {
755
731
async apiV1BesuRunTransaction ( runTransactionRequest ?: RunTransactionRequest , options ?: any ) : Promise < ( axios ?: AxiosInstance , basePath ?: string ) => AxiosPromise < RunTransactionResponse > > {
756
732
const localVarAxiosArgs = await DefaultApiAxiosParamCreator ( configuration ) . apiV1BesuRunTransaction ( runTransactionRequest , options ) ;
757
733
return ( axios : AxiosInstance = globalAxios , basePath : string = BASE_PATH ) => {
758
- const axiosRequestArgs = { ...localVarAxiosArgs . options , url : ( configuration ?. basePath || basePath ) + localVarAxiosArgs . url } ;
734
+ const axiosRequestArgs = { ...localVarAxiosArgs . options , url : basePath + localVarAxiosArgs . url } ;
759
735
return axios . request ( axiosRequestArgs ) ;
760
736
} ;
761
737
} ,
@@ -769,7 +745,7 @@ export const DefaultApiFp = function(configuration?: Configuration) {
769
745
async signTransactionV1 ( signTransactionRequest : SignTransactionRequest , options ?: any ) : Promise < ( axios ?: AxiosInstance , basePath ?: string ) => AxiosPromise < SignTransactionResponse > > {
770
746
const localVarAxiosArgs = await DefaultApiAxiosParamCreator ( configuration ) . signTransactionV1 ( signTransactionRequest , options ) ;
771
747
return ( axios : AxiosInstance = globalAxios , basePath : string = BASE_PATH ) => {
772
- const axiosRequestArgs = { ...localVarAxiosArgs . options , url : ( configuration ?. basePath || basePath ) + localVarAxiosArgs . url } ;
748
+ const axiosRequestArgs = { ...localVarAxiosArgs . options , url : basePath + localVarAxiosArgs . url } ;
773
749
return axios . request ( axiosRequestArgs ) ;
774
750
} ;
775
751
} ,
0 commit comments