From aa13bc9c7336ee71f735098901d99f2ead90dad1 Mon Sep 17 00:00:00 2001 From: xelius Date: Fri, 24 May 2013 01:46:32 +0300 Subject: [PATCH] Update collections2.html Minor edit in code example. --- content/collections2.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/content/collections2.html b/content/collections2.html index 046536b..208dd12 100644 --- a/content/collections2.html +++ b/content/collections2.html @@ -202,7 +202,7 @@

Using the Model class

So, how can we use this model class? Here is a simple example of how to define a model:

function Photo(attr) {
-  Model.prototype.apply(this, attr);
+  Model.apply(this, attr);
 }
 
 Photo.prototype = new Model();
@@ -223,7 +223,7 @@ 

Using the Model class

function Photo(attr) {
   attr.src || (attr.src = 'default.jpg');
-  Model.prototype.apply(this, attr);
+  Model.apply(this, attr);
 }