mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-13 22:41:32 -05:00
Merge pull request #4653 from jaswilli/client-data
Do not include url and author_id in post payload.
This commit is contained in:
commit
7d0deebc08
1 changed files with 6 additions and 2 deletions
|
@ -52,10 +52,14 @@ var PostSerializer = ApplicationSerializer.extend(DS.EmbeddedRecordsMixin, {
|
|||
var root = Ember.String.pluralize(type.typeKey),
|
||||
data = this.serialize(record, options);
|
||||
|
||||
// Don't ever pass uuid's
|
||||
// Properties that exist on the model but we don't want sent in the payload
|
||||
|
||||
delete data.uuid;
|
||||
// Don't send HTML
|
||||
delete data.html;
|
||||
// Inserted locally as a convenience.
|
||||
delete data.author_id;
|
||||
// Read-only virtual property.
|
||||
delete data.url;
|
||||
|
||||
hash[root] = [data];
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue