Ghost/ghost/admin/app/serializers/member.js
Rish 5a609a785f Enabled write operation for member name and note
no issue

- Allows editing member's name and note in admin
2019-10-10 17:29:35 +05:30

16 lines
486 B
JavaScript

/* eslint-disable camelcase */
import ApplicationSerializer from 'ghost-admin/serializers/application';
export default ApplicationSerializer.extend({
serialize(/*snapshot, options*/) {
let json = this._super(...arguments);
// Properties that exist on the model but we don't want sent in the payload
delete json.stripe;
// Normalize properties
json.name = json.name || '';
json.note = json.note || '';
return json;
}
});