From f7f52c93240d48643306b9724a6f2972f9b65a7c Mon Sep 17 00:00:00 2001 From: Nathan Loisel Date: Thu, 15 Dec 2016 13:26:54 +0100 Subject: [PATCH] Fix set text=0 dynamically --- src/main.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.js b/src/main.js index 250404e..730979e 100644 --- a/src/main.js +++ b/src/main.js @@ -90,7 +90,7 @@ var Shape = React.createClass({ }, _setText: function _setText(text) { - if (text) { + if (typeof text !== 'undefined' && text !== null) { this.state.shape.setText(text); } }