Socket
Socket
Sign inDemoInstall

vendease-common

Package Overview
Dependencies
185
Maintainers
1
Versions
52
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 2.1.13 to 2.1.14

build/examples/product.d.ts

3

build/events/v1/base/listener.js

@@ -5,2 +5,3 @@ "use strict";

const logger_1 = require("../../../util/logger");
const notifications_1 = require("../../../notifications");
class Listener {

@@ -14,4 +15,4 @@ constructor(client) {

this.consumMessage = (msg) => {
console.log(this.onMessage);
logger_1.logger.info(`Message received: ${this.subject} / ${this.queueGroupName}`);
notifications_1.slackNotification.send(`Message received: ${this.subject} / ${this.queueGroupName}`, false);
const parsedData = this.parseMessage(msg);

@@ -18,0 +19,0 @@ logger_1.logger.info(`consuming message....`);

@@ -5,2 +5,3 @@ "use strict";

const logger_1 = require("../../../util/logger");
const notifications_1 = require("../../../notifications");
class Publisher {

@@ -11,10 +12,11 @@ constructor(client) {

publish(data) {
const self = this;
logger_1.logger.info(`Publishing to ${self.subject}`);
logger_1.logger.info(`Publishing to ${this.subject}`);
return new Promise((resolve, reject) => {
this.client.publish(self.subject, JSON.stringify(data), (err) => {
this.client.publish(this.subject, JSON.stringify(data), (err) => {
if (err) {
notifications_1.slackNotification.send(err.message, true);
return reject(err);
}
logger_1.logger.info(`Event published to subject [${self.subject}]`);
logger_1.logger.info(`Event published to subject [${this.subject}]`);
notifications_1.slackNotification.send(JSON.stringify(data), false);
resolve();

@@ -21,0 +23,0 @@ });

{
"name": "vendease-common",
"version": "2.1.13",
"version": "2.1.14",
"description": "",

@@ -31,2 +31,3 @@ "main": "./build/index.js",

"devDependencies": {
"@faker-js/faker": "^8.0.2",
"@types/jest": "^29.5.3",

@@ -51,2 +52,3 @@ "@types/supertest": "^2.0.12",

"@types/sequelize": "^4.28.15",
"axios": "^1.5.0",
"bcryptjs": "2.4.3",

@@ -53,0 +55,0 @@ "cookie-session": "^1.4.0",

SocketSocket SOC 2 Logo

Product

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

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc