ember-cli-simple-store
Advanced tools
Comparing version 0.8.5 to 0.9.0
@@ -76,3 +76,3 @@ import Ember from "ember"; | ||
} | ||
return this._findByIdComputed(type, options); | ||
return this._findById(type, options); | ||
}, | ||
@@ -83,14 +83,2 @@ findOne: function(type) { | ||
}, | ||
_findByIdComputed: function(type, id) { | ||
var actualId = this._parseAndTransformId(id); | ||
return Ember.ObjectProxy.extend({ | ||
content: function() { | ||
var filter_value = this.get("filter_value"); | ||
return this.get("source").filterBy("id", filter_value).objectAt(0); | ||
}.property("source.[]") | ||
}).create({ | ||
filter_value: actualId, | ||
source: this._findAll(type) | ||
}); | ||
}, | ||
_findById: function(type, id) { | ||
@@ -129,9 +117,2 @@ var identityMap = identityMapForType(type, this); | ||
}); | ||
}, | ||
_parseAndTransformId: function(id) { | ||
var numberId = parseInt(id, 10); | ||
if (numberId && numberId.toString().length === id.toString().length) { | ||
return numberId; | ||
} | ||
return id; | ||
} | ||
@@ -138,0 +119,0 @@ }); |
{ | ||
"name": "ember-cli-simple-store", | ||
"version": "0.8.5", | ||
"version": "0.9.0", | ||
"description": "ember-cli addon that provides a simple identity map for ember.js web applications", | ||
@@ -5,0 +5,0 @@ "directories": { |
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
0
16164
10
208