Update procedure generators

This commit is contained in:
Rachel Fenichel
2018-01-02 16:27:17 -08:00
parent 24cf1cf7dd
commit 9b091a8f9e
7 changed files with 68 additions and 8 deletions

View File

@@ -152,11 +152,9 @@ Blockly.PHP.init = function(workspace) {
Blockly.PHP.variableDB_.setVariableMap(workspace.getVariableMap());
var defvars = [];
var varName;
var variables = workspace.getAllVariables();
for (var i = 0, variable; variable = variables[i]; i++) {
varName = variable.name;
defvars[i] = Blockly.PHP.variableDB_.getName(varName,
defvars[i] = Blockly.PHP.variableDB_.getName(variable.getId(),
Blockly.Variables.NAME_TYPE) + ';';
}