From 7a5f65b93e819b0919ddd5eb427bc381722eadd1 Mon Sep 17 00:00:00 2001 From: Arvind Date: Wed, 5 Mar 2014 19:13:17 +0530 Subject: [PATCH] Overriding Comment.toJSON to return the required json object. Default toJSON did not ``unvivify`` the model in how attribute. --- app.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/app.js b/app.js index e710c97..6945743 100644 --- a/app.js +++ b/app.js @@ -35,8 +35,7 @@ initialize: function() { }, toJSON: function() { - how = this.get('how').toJSON(); - return this; + return JSON.parse(JSON.stringify(this.attributes)); } }); -- 1.7.10.4