0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-02-24 23:48:13 -05:00

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.
This commit is contained in:
Jason Williams 2015-01-25 19:57:20 +00:00
parent 245b0bea12
commit f0d7a918a1
2 changed files with 0 additions and 30 deletions

View file

@ -30,21 +30,6 @@ var PostSerializer = ApplicationSerializer.extend(DS.EmbeddedRecordsMixin, {
return this._super.apply(this, arguments); 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) { serializeIntoHash: function (hash, type, record, options) {
options = options || {}; options = options || {};
options.includeId = true; options.includeId = true;

View file

@ -13,21 +13,6 @@ var UserSerializer = ApplicationSerializer.extend(DS.EmbeddedRecordsMixin, {
delete payload[pluralizedRoot]; delete payload[pluralizedRoot];
return this._super.apply(this, arguments); 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;
} }
}); });