diff --git a/core/field.js b/core/field.js index ad7477830..a9d7b919c 100644 --- a/core/field.js +++ b/core/field.js @@ -557,8 +557,10 @@ Blockly.Field.prototype.updateColour = function() { * @protected */ Blockly.Field.prototype.render_ = function() { - this.textContent_.nodeValue = this.getDisplayText_(); - this.updateSize_(); + if (this.textContent_) { + this.textContent_.nodeValue = this.getDisplayText_(); + this.updateSize_(); + } }; /**