From 4a5f0a0bf15b21fbdc8338ef612617977bf6b727 Mon Sep 17 00:00:00 2001 From: Ryan Loader Date: Tue, 17 Feb 2015 11:35:37 +1300 Subject: [PATCH] Fixed issue with mutated function call blocks --- blocks/procedures.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/blocks/procedures.js b/blocks/procedures.js index a11839aa7..261a4d902 100644 --- a/blocks/procedures.js +++ b/blocks/procedures.js @@ -594,15 +594,15 @@ Blockly.Blocks['procedures_callnoreturn'] = { // Initialize caller with the mutator's IDs. this.setProcedureParameters(def.arguments_, def.paramIds_); } else { - this.arguments_ = []; + var args = []; for (var i = 0, childNode; childNode = xmlElement.childNodes[i]; i++) { if (childNode.nodeName.toLowerCase() == 'arg') { - this.arguments_.push(childNode.getAttribute('name')); + args.push(childNode.getAttribute('name')); } } // For the second argument (paramIds) use the arguments list as a dummy // list. - this.setProcedureParameters(this.arguments_, this.arguments_); + this.setProcedureParameters(args, args); } }, /**