@lexamica-modules/job-queue
Version:
The package for the Lexamica Job Queue SDK powered by Redis and BullMQ
15 lines (14 loc) • 583 B
TypeScript
/**
* This function logs out an error and optionally throws it further if specified
* @param options
* @param {string} options.message The error message to log
* @param {string} options.job The job name or ID
* @param {Error} options.error The actual error being handled
* @param {boolean} options.handle Default to true, but if set to false, error will be thrown through once it has been logged.
*/
export declare function handleErrorWithInfo({ message, job, error, handle, }: {
message: string;
job: string;
error: Error;
handle?: boolean;
}): void | Error;