From b47f1bbcd8e96b591925ff795acc359accf7a9ad Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Wed, 17 Apr 2013 20:40:13 +0200 Subject: [PATCH] Added cancel button. Fixed bug in object cloning. --- js/h5p.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/h5p.js b/js/h5p.js index e082212..4265b9a 100644 --- a/js/h5p.js +++ b/js/h5p.js @@ -281,7 +281,7 @@ H5P.cloneObject = function (object, recursive) { for (var i in object) { if (object.hasOwnProperty(i)) { if (recursive !== undefined && recursive && typeof object[i] === 'object') { - clone[i] = object[i] instanceof Array ? object[i].slice() : H5P.cloneObject(object[i]); + clone[i] = object[i] instanceof Array ? object[i].slice() : H5P.cloneObject(object[i], recursive); } else { clone[i] = object[i];