Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@appolo/bus

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@appolo/bus - npm Package Compare versions

Comparing version 8.0.6 to 8.0.7

10

module/src/messages/messageManager.js

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

try {
let instance = this.injector.parent.get(handler.define.definition.id);
let instance = this._getHandlerInjector(handler).get(handler.define.definition.id);
await instance[handler.propertyKey](msg);

@@ -59,5 +59,11 @@ if (!msg.isAcked) {

}
_getHandlerInjector(handler) {
let def = handler.define.definition, injector = def.injector && def.injector.hasDefinition(def.id)
? def.injector
: this.injector.parent;
return injector;
}
async _callReply(msg, handler) {
try {
let instance = this.injector.parent.get(handler.define.definition.id);
let instance = this._getHandlerInjector(handler).get(handler.define.definition.id);
let data = await instance[handler.propertyKey](msg);

@@ -64,0 +70,0 @@ if (!msg.isAcked) {

15

module/src/messages/messageManager.ts

@@ -82,4 +82,5 @@ import {define, inject, Injector, singleton} from "@appolo/inject";

try {
let instance = this.injector.parent.get(handler.define.definition.id);
let instance = this._getHandlerInjector(handler).get(handler.define.definition.id);
await instance[handler.propertyKey](msg);

@@ -101,7 +102,17 @@ if (!msg.isAcked) {

private _getHandlerInjector(handler: IHandler): Injector {
let def = handler.define.definition,
injector = def.injector && def.injector.hasDefinition(def.id)
? def.injector
: this.injector.parent;
return injector;
}
private async _callReply(msg: Message<any>, handler: IHandler) {
try {
let instance = this.injector.parent.get(handler.define.definition.id);
let instance = this._getHandlerInjector(handler).get(handler.define.definition.id);
let data = await instance[handler.propertyKey](msg);

@@ -108,0 +119,0 @@

{
"name": "@appolo/bus",
"version": "8.0.6",
"version": "8.0.7",
"description": "appolo bus module",

@@ -5,0 +5,0 @@ "publishConfig": {

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