Skip to content

Commit

Permalink
remove apm dep
Browse files Browse the repository at this point in the history
  • Loading branch information
smith committed Feb 1, 2021
1 parent 81b421b commit b8d4e39
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
* you may not use this file except in compliance with the Elastic License.
*/

import { PromiseValueType } from '../../../apm/typings/common';
import type { UnwrapPromise } from '@kbn/utility-types';

export function unwrapEsResponse<T extends Promise<{ body: any }>>(
responsePromise: T
): Promise<PromiseValueType<T>['body']> {
): Promise<UnwrapPromise<T>['body']> {
return responsePromise.then((res) => res.body);
}

0 comments on commit b8d4e39

Please sign in to comment.