From f794490e61d9108782cf6ec2b6101953f4eaa18e Mon Sep 17 00:00:00 2001 From: Jason Williams Date: Sun, 25 Jan 2015 19:57:20 +0000 Subject: [PATCH] Update Ember-Data, remove unneeded code No Issue. - Ember-Data@1.0.0-beta.14.1. - Remove code from serializers for a workaround that's no longer needed. --- bower.json | 2 +- core/client/serializers/post.js | 15 --------------- core/client/serializers/user.js | 15 --------------- 3 files changed, 1 insertion(+), 31 deletions(-) diff --git a/bower.json b/bower.json index bbd1b846f6..690233ef8f 100644 --- a/bower.json +++ b/bower.json @@ -5,7 +5,7 @@ "Countable": "2.0.2", "device": "git://github.com/matthewhudson/device.js#5347a275b66020a0d4dfe9aad81a488f8cce448d", "ember": "1.9.0", - "ember-data": "1.0.0-beta.12", + "ember-data": "1.0.0-beta.14.1", "ember-load-initializers": "git://github.com/stefanpenner/ember-load-initializers.git#0.0.1", "ember-resolver": "git://github.com/stefanpenner/ember-jj-abrams-resolver.git#181251821cf513bb58d3e192faa13245a816f75e", "ember-simple-auth": "0.7.2", diff --git a/core/client/serializers/post.js b/core/client/serializers/post.js index ba8704bff6..e668ac22eb 100644 --- a/core/client/serializers/post.js +++ b/core/client/serializers/post.js @@ -30,21 +30,6 @@ var PostSerializer = ApplicationSerializer.extend(DS.EmbeddedRecordsMixin, { return this._super.apply(this, arguments); }, - keyForAttribute: function (attr) { - return attr; - }, - - keyForRelationship: function (relationshipName) { - // this is a hack to prevent Ember-Data from deleting our `tags` reference. - // ref: https://github.com/emberjs/data/issues/2051 - // @TODO: remove this once the situation becomes clearer what to do. - if (relationshipName === 'tags') { - return 'tag'; - } - - return relationshipName; - }, - serializeIntoHash: function (hash, type, record, options) { options = options || {}; options.includeId = true; diff --git a/core/client/serializers/user.js b/core/client/serializers/user.js index 2ee6a886b0..b83b0b52c7 100644 --- a/core/client/serializers/user.js +++ b/core/client/serializers/user.js @@ -13,21 +13,6 @@ var UserSerializer = ApplicationSerializer.extend(DS.EmbeddedRecordsMixin, { delete payload[pluralizedRoot]; return this._super.apply(this, arguments); - }, - - keyForAttribute: function (attr) { - return attr; - }, - - keyForRelationship: function (relationshipName) { - // this is a hack to prevent Ember-Data from deleting our `tags` reference. - // ref: https://github.com/emberjs/data/issues/2051 - // @TODO: remove this once the situation becomes clearer what to do. - if (relationshipName === 'roles') { - return 'role'; - } - - return relationshipName; } });