react-services-injector
Advanced tools
Comparing version 0.2.0-beta.3 to 0.2.0-beta.4
12
index.js
@@ -72,7 +72,9 @@ let Service = function() { | ||
disconnectInstance(id) { | ||
let components = this.components.slice(0); | ||
this.components.length = 0; | ||
this.components.concat(components.filter(item => item.key !== id)); | ||
disconnectInstance(key) { | ||
this.components.some((component, index) => { | ||
if (component.key === key) { | ||
this.components.splice(index, 1); | ||
return true; | ||
} | ||
}); | ||
} | ||
@@ -79,0 +81,0 @@ |
{ | ||
"name": "react-services-injector", | ||
"version": "0.2.0-beta.3", | ||
"version": "0.2.0-beta.4", | ||
"description": "A library to create and use sigleton-services in your React application.", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
34610
92