Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'add-json-attr' into custom-build

  • Loading branch information...
commit 25c466528f78563b41ce8ec83cb5c2029d4c56a8 2 parents 7ed415c + 4c61cda
@joewest authored
Showing with 10 additions and 0 deletions.
  1. +10 −0 packages/ember-data/lib/system/model/attributes.js
View
10 packages/ember-data/lib/system/model/attributes.js
@@ -133,6 +133,16 @@ DS.attr.transforms = {
}
},
+ json: {
+ from: function(serialized) {
+ return Ember.none(serialized) ? null : serialized;
+ },
+
+ to: function(deserialized) {
+ return Ember.none(deserialized) ? null : deserialized;
+ }
+ },
+
date: {
from: function(serialized) {
var type = typeof serialized;
Please sign in to comment.
Something went wrong with that request. Please try again.