From 5f642c47d3fd1d4404c0a3d1c366239ac9da8dc6 Mon Sep 17 00:00:00 2001 From: Matěj Cepl Date: Thu, 17 Mar 2011 16:50:34 +0100 Subject: Removing apply in createDeadLink was a bad idea. --- data/lib/util.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'data/lib') diff --git a/data/lib/util.js b/data/lib/util.js index 1b5c37d..e51a657 100644 --- a/data/lib/util.js +++ b/data/lib/util.js @@ -115,10 +115,10 @@ function createDeadLink (id, text, parent, callback, params, before, covered, ac } else { newAElem.setAttribute("href", ""); newAElem.addEventListener("click", function(evt) { - // callback.apply(null, params); - callback(params); evt.stopPropagation(); evt.preventDefault(); + // We need apply, because params could be array of parameters + callback.apply(null, params); }, false); } -- cgit