Przeglądaj źródła

Fix type for exists method in indices to return correct response type

Shun Miyazawa 9 miesięcy temu
rodzic
commit
26be5bbd92

+ 1 - 1
apps/app/src/server/service/search-delegator/elasticsearch-client-delegator/es7-client-delegator.ts

@@ -30,7 +30,7 @@ export class ES7ClientDelegator {
   indices = {
   indices = {
     create: (params: RequestParams.IndicesCreate): Promise<ApiResponse<estypes.IndicesCreateResponse>> => this.client.indices.create(params),
     create: (params: RequestParams.IndicesCreate): Promise<ApiResponse<estypes.IndicesCreateResponse>> => this.client.indices.create(params),
     delete: (params: RequestParams.IndicesDelete): Promise<ApiResponse<estypes.IndicesDeleteResponse>> => this.client.indices.delete(params),
     delete: (params: RequestParams.IndicesDelete): Promise<ApiResponse<estypes.IndicesDeleteResponse>> => this.client.indices.delete(params),
-    exists: (params: RequestParams.IndicesExists): Promise<ApiResponse<estypes.IndicesDeleteResponse>> => this.client.indices.exists(params),
+    exists: (params: RequestParams.IndicesExists): Promise<ApiResponse<estypes.IndicesExistsResponse>> => this.client.indices.exists(params),
     existsAlias: (params: RequestParams.IndicesExistsAlias): Promise<ApiResponse<estypes.IndicesExistsAliasResponse>> => {
     existsAlias: (params: RequestParams.IndicesExistsAlias): Promise<ApiResponse<estypes.IndicesExistsAliasResponse>> => {
       return this.client.indices.existsAlias(params);
       return this.client.indices.existsAlias(params);
     },
     },