Strip out id from DataSet JSON before saving.
authorDavid Schoonover <dsc@wikimedia.org>
Wed, 6 Jun 2012 12:47:55 +0000 (05:47 -0700)
committerDavid Schoonover <dsc@wikimedia.org>
Wed, 6 Jun 2012 12:47:55 +0000 (05:47 -0700)
lib/data/dataset-model.co

index b96480b..e24a6aa 100644 (file)
@@ -100,6 +100,12 @@ DataSet = exports.DataSet = BaseModel.extend do # {{{
         DataSet.__super__.set.call this, values, opts
     
     
+    toJSON: ->
+        json = DataSet.__super__.toJSON ...
+        delete json.id
+        json
+    
+    
     /* * * *  TimeSeriesData interface  * * * {{{ */
     
     /**