Fix IE11 for in bug in motor field (#513)

* Fix IE11 for in bug in motor field

* minor fix
This commit is contained in:
Sam El-Husseini 2018-04-13 15:21:41 -07:00 committed by GitHub
parent 87b08bf6f3
commit 23c1789976
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -406,7 +406,7 @@ export class FieldMotors extends Blockly.FieldDropdown implements Blockly.FieldC
let opts = {};
let conts = {};
let vals = {};
for (let opt in options) {
for (let opt = 0; opt < options.length; opt++) {
let text = options[opt][0].alt ? options[opt][0].alt : options[opt][0];
if (text.indexOf(' ') == -1) {
// Patch dual motors as they don't have prefixes.