Skip to content

Commit

Permalink
ember 3.0
Browse files Browse the repository at this point in the history
  • Loading branch information
GavinJoyce committed Apr 20, 2018
1 parent 868550c commit 3c48920
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 18 deletions.
16 changes: 3 additions & 13 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"author": "no",
"license": "MIT",
"devDependencies": {
"ember-source": "2.18.2",
"ember-source": "3.0.0",
"glob": "~3.2.1",
"grunt": "~1.0.1",
"grunt-contrib-clean": "~0.4.1",
Expand Down
3 changes: 1 addition & 2 deletions packages/ember-model/lib/model.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,7 @@ Ember.Model = Ember.Object.extend(Ember.Evented, {
var relationships = this.constructor._relationships || [], meta = Ember.meta(this), relationshipKey, relationship, relationshipMeta, relationshipData, relationshipType;
for (var i = 0, l = relationships.length; i < l; i++) {
relationshipKey = relationships[i];
relationship = (meta.descs || this)[relationshipKey];
relationshipMeta = relationship.meta();
relationshipMeta = this.constructor.metaForProperty(relationshipKey);

if (relationshipMeta.options.embedded) {
relationshipType = relationshipMeta.type;
Expand Down
4 changes: 2 additions & 2 deletions packages/ember-model/tests/filtered_record_array_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ QUnit.test("must be created with a filterFunction property", function(assert) {

QUnit.test("must be created with a filterProperties property", function(assert) {
assert.throws(function() {
Ember.FilteredRecordArray.create({modelClass: Model, filterFunction: Ember.K});
Ember.FilteredRecordArray.create({modelClass: Model, filterFunction: () => {} });
}, /FilteredRecordArrays must be created with filterProperties/);
});

Expand All @@ -42,7 +42,7 @@ QUnit.test("with a noop filter will return all the loaded records", function(ass
Model.fetch().then(function() {
var recordArray = Ember.FilteredRecordArray.create({
modelClass: Model,
filterFunction: Ember.K,
filterFunction: () => { return true; },
filterProperties: []
});

Expand Down

0 comments on commit 3c48920

Please sign in to comment.