@arizeai/phoenix-client
Version:
A client for the Phoenix API
11 lines • 350 B
JavaScript
/**
* If the incoming function returns a promise, return the promise.
* Otherwise, return a promise that resolves to the incoming function's return value.
*/
export function promisifyResult(result) {
if (result instanceof Promise) {
return result;
}
return Promise.resolve(result);
}
//# sourceMappingURL=promisifyResult.js.map