diff options
author | Timotej Lazar <timotej.lazar@fri.uni-lj.si> | 2016-02-23 13:57:15 +0100 |
---|---|---|
committer | Timotej Lazar <timotej.lazar@fri.uni-lj.si> | 2016-02-23 14:00:24 +0100 |
commit | b818c258629135179731fbc851e38f07d2c1a4bb (patch) | |
tree | ad492cdbd32f125c9c6759aa52708a7d933b6846 | |
parent | 95c2636cdab6d1040beeb3105659104a3d1842a4 (diff) |
Remove redundant parameter from static hint handler
-rw-r--r-- | js/codeq/hint.js | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/js/codeq/hint.js b/js/codeq/hint.js index 1d0ff09..b26f522 100644 --- a/js/codeq/hint.js +++ b/js/codeq/hint.js @@ -180,8 +180,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. */ }, typeHandlers = { - 'static': function (template, serverHint, hintId) { - var content = prepareStaticHintContent(template, serverHint.indices, hintId), + 'static': function (template, serverHint) { + var content = prepareStaticHintContent(template, serverHint.indices, serverHint.id), args = serverHint ? serverHint.args : null, hintIndex = 0, trButton = {}, @@ -204,7 +204,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. */ } } catch (e) { - msg = 'Error processing hint ' + hintId + ' at index ' + hintIndex + ' for language ' + lang + ': ' + e; + msg = 'Error processing hint ' + serverHint.id + ' at index ' + hintIndex + ' for language ' + lang + ': ' + e; codeq.log.error(msg, e); trContent[lang] = msg; } @@ -349,7 +349,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. */ */ 'planNext': function () { if (planIdx < planDef.length) { - typeHandlers['static'](planDef[planIdx], {}, 'plan'); + typeHandlers['static'](planDef[planIdx], {'id': 'plan'}); planIdx++; } return planIdx < planDef.length; @@ -397,7 +397,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. */ fn = typeHandlers[hintType]; if (!fn) codeq.log.error('Unsupported hint type: ' + hintType); else { - ret = fn(hintContent, serverHint, hintId); + ret = fn(hintContent, serverHint); if (typeof ret === 'function') finalizers.push(ret); } } |