UNPKG

@ioredis/as-callback

Version:

A performant and standard (Bluebird) library that registers a node-style callback on a promise

10 lines (9 loc) 262 B
import { CallbackFunction } from "./types"; export declare const errorObj: { e: {}; }; declare function tryCatcher<T>(err: Error, val?: T): void | { e: Error; }; export declare function tryCatch<T>(fn: CallbackFunction<T>): typeof tryCatcher; export {};