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

@evosphere/legato

Package Overview
Dependencies
Maintainers
2
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@evosphere/legato - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

31

index.js

@@ -59,11 +59,5 @@ // @flow

*/
function Bundle(params : { name: string }) {
let definitions = {};
function Bundle(params : { name: string, definitions: () => ServiceMap }) {
this.name = params.name;
this.register = function(ref : string, service : ServiceType) {
definitions[ref] = service;
};
this.getDefinitions = () => definitions;
this.getDefinitions = params.getDefinitions.bind(this);
}

@@ -85,2 +79,8 @@

if(typeof params.getDefinitions !== "function") {
throw new Error(
"You must provide a getDefinitions function that will return an object whose keys are" +
"references and values services."
)
}
return new Bundle(params);

@@ -113,2 +113,3 @@ };

let initialized : boolean = false;
let bundles = [];

@@ -154,2 +155,7 @@ /**

if(Object.keys(definitions).length === 0) {
initialized = true;
return;
}
let currentDef;

@@ -207,6 +213,7 @@ let keepGoing = true;

addBundle(bundle : BundleType) {
let definitions = bundle.getDefinitions();
for(let ref in definitions) {
if(definitions.hasOwnProperty(ref)) {
this.register(ref, definitions[ref]);
bundles.push(bundle);
const bundleDefs = bundle.getDefinitions();
for(let ref in bundleDefs) {
if(bundleDefs.hasOwnProperty(ref)) {
this.register(ref, bundleDefs[ref]);
}

@@ -213,0 +220,0 @@ }

{
"name": "@evosphere/legato",
"version": "0.0.1",
"version": "0.0.2",
"description": "Service management system",

@@ -23,3 +23,6 @@ "main": "index.js",

"jest": "^20.0.4"
},
"dependencies": {
"shaara-core": "^0.1.0"
}
}

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