diff options
Diffstat (limited to 'packages/aml-backoffice-ui/src/hooks/useBackend.ts')
-rw-r--r-- | packages/aml-backoffice-ui/src/hooks/useBackend.ts | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/packages/aml-backoffice-ui/src/hooks/useBackend.ts b/packages/aml-backoffice-ui/src/hooks/useBackend.ts index e68efb2e3..b9d66fca6 100644 --- a/packages/aml-backoffice-ui/src/hooks/useBackend.ts +++ b/packages/aml-backoffice-ui/src/hooks/useBackend.ts @@ -14,7 +14,7 @@ interface useBackendType { path: string, options?: RequestOptions, ) => Promise<HttpResponseOk<T>>; - fetcher: <T>(endpoint: string) => Promise<HttpResponseOk<T>>; + fetcher: <T>(args: [string, string]) => Promise<HttpResponseOk<T>>; paginatedFetcher: <T>( args: [string, number, number, string], ) => Promise<HttpResponseOk<T>>; @@ -35,8 +35,10 @@ export function usePublicBackend(): useBackendType { ); const fetcher = useCallback( - function fetcherImpl<T>(endpoint: string): Promise<HttpResponseOk<T>> { - return requestHandler<T>(baseUrl, endpoint); + function fetcherImpl<T>([endpoint, talerAmlOfficerSignature]: [string,string]): Promise<HttpResponseOk<T>> { + return requestHandler<T>(baseUrl, endpoint, { + talerAmlOfficerSignature + }); }, [baseUrl], ); |