From 1c45724e37134c79f5889b196db86058b78f6b85 Mon Sep 17 00:00:00 2001 From: Andrew n marshall Date: Wed, 19 Apr 2017 14:38:22 -0700 Subject: [PATCH] Correcting #1054 (#1056) single quotes. better logic. --- core/input.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/core/input.js b/core/input.js index 346c3b7cc..c2c006e52 100644 --- a/core/input.js +++ b/core/input.js @@ -41,9 +41,8 @@ goog.require('goog.asserts'); * @constructor */ Blockly.Input = function(type, name, block, connection) { - if (!name && - (type == Blockly.INPUT_VALUE || type == Blockly.NEXT_STATEMENT)) { - throw "Value inputs and statement inputs must have non-empty name."; + if (type != Blockly.DUMMY_INPUT && !name) { + throw 'Value inputs and statement inputs must have non-empty name.'; } /** @type {number} */ this.type = type;