Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge pull request #817 from tricknotes/remove-unused

Remove unused variables and helper functions
  • Loading branch information...
commit 4a184792886ddc8100154b06ad6ff12949a4c44f 2 parents 830420a + 35fbc5e
@stefanpenner stefanpenner authored
View
2  packages/ember-data/lib/system/model/model.js
@@ -3,7 +3,7 @@ require("ember-data/system/mixins/load_promise");
var LoadPromise = DS.LoadPromise; // system/mixins/load_promise
-var get = Ember.get, set = Ember.set, none = Ember.isNone, map = Ember.EnumerableUtils.map;
+var get = Ember.get, set = Ember.set, map = Ember.EnumerableUtils.map;
var retrieveFromCurrentState = Ember.computed(function(key, value) {
if (arguments.length > 1) {
View
18 packages/ember-data/lib/system/model/states.js
@@ -1,4 +1,4 @@
-var get = Ember.get, set = Ember.set, guidFor = Ember.guidFor,
+var get = Ember.get, set = Ember.set,
once = Ember.run.once, arrayMap = Ember.ArrayPolyfills.map;
/**
@@ -159,14 +159,6 @@ var stateProperty = Ember.computed(function(key) {
}
}).property();
-var isEmptyObject = function(object) {
- for (var name in object) {
- if (object.hasOwnProperty(name)) { return false; }
- }
-
- return true;
-};
-
var hasDefinedProperties = function(object) {
for (var name in object) {
if (object.hasOwnProperty(name) && object[name]) { return true; }
@@ -193,12 +185,6 @@ var didSetProperty = function(manager, context) {
change.sync();
};
-// Whenever a property is set, recompute all dependent filters
-var updateRecordArrays = function(manager) {
- var record = manager.get('record');
- record.updateRecordArraysLater();
-};
-
DS.State = Ember.State.extend({
isLoaded: stateProperty,
isReloading: stateProperty,
@@ -543,7 +529,7 @@ var states = {
exit: function(manager) {
var record = get(manager, 'record');
- Ember.run.once(function() {
+ once(function() {
record.trigger('didLoad');
});
}
Please sign in to comment.
Something went wrong with that request. Please try again.