Socket
Socket
Sign inDemoInstall

@bull-board/api

Package Overview
Dependencies
Maintainers
1
Versions
145
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@bull-board/api - npm Package Compare versions

Comparing version 3.7.2 to 3.8.0

2

dist/src/handlers/queues.js

@@ -40,3 +40,3 @@ "use strict";

data: queue.format('data', jobProps.data),
name: jobProps.name,
name: queue.format('name', jobProps),
returnValue: queue.format('returnValue', jobProps.returnvalue),

@@ -43,0 +43,0 @@ isFailed: !!jobProps.failedReason || (Array.isArray(stacktrace) && stacktrace.length > 0),

@@ -1,2 +0,2 @@

import { JobCleanStatus, JobCounts, JobStatus, QueueAdapterOptions, QueueJob } from '../../typings/app';
import { FormatterField, JobCleanStatus, JobCounts, JobStatus, QueueAdapterOptions, QueueJob } from '../../typings/app';
export declare abstract class BaseAdapter {

@@ -7,4 +7,4 @@ readonly readOnlyMode: boolean;

protected constructor(options?: Partial<QueueAdapterOptions>);
setFormatter(field: 'data' | 'returnValue', formatter: (data: any) => any): void;
format(field: 'data' | 'returnValue', data: any): any;
setFormatter(field: FormatterField, formatter: (data: any) => any): void;
format(field: FormatterField, data: any): any;
abstract clean(queueStatus: JobCleanStatus, graceTimeMs: number): Promise<void>;

@@ -11,0 +11,0 @@ abstract getJob(id: string): Promise<QueueJob | undefined | null>;

@@ -15,3 +15,6 @@ "use strict";

format(field, data) {
return typeof this.formatters[field] === 'function' ? this.formatters[field](data) : data;
const defaultValue = field === 'name' ? data.name : data;
return typeof this.formatters[field] === 'function'
? this.formatters[field](data)
: defaultValue;
}

@@ -18,0 +21,0 @@ }

@@ -112,1 +112,2 @@ import { BaseAdapter } from '../src/queueAdapters/base';

}
export declare type FormatterField = 'data' | 'returnValue' | 'name';
{
"name": "@bull-board/api",
"version": "3.7.2",
"version": "3.8.0",
"description": "Core server APIs of bull-board",

@@ -5,0 +5,0 @@ "keywords": [

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc