diff options
| author | Gubolin <gubolin@fantasymail.de> | 2014-08-02 16:31:20 +0200 |
|---|---|---|
| committer | Gubolin <gubolin@fantasymail.de> | 2014-08-02 16:31:20 +0200 |
| commit | 55d04ca5f2a80ec815531510f68616ea22618abb (patch) | |
| tree | e5a6eaa913fcf049fef1cb0a8677b7a87a11ff18 | |
| parent | 0333925e916acc47c25cdcfec0c3be3d695a825f (diff) | |
| download | snap-55d04ca5f2a80ec815531510f68616ea22618abb.tar.gz snap-55d04ca5f2a80ec815531510f68616ea22618abb.zip | |
allow percent symbols in custom block texts (fix #361)
| -rw-r--r-- | byob.js | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -227,7 +227,7 @@ CustomBlockDefinition.prototype.blockSpec = function () { parts = this.parseSpec(this.spec), spec; parts.forEach(function (part) { - if (part[0] === '%') { + if (part[0] === '%' && part.length > 1) { spec = myself.typeOf(part.slice(1)); } else { spec = part; @@ -311,7 +311,7 @@ CustomBlockDefinition.prototype.inputNames = function () { var vNames = [], parts = this.parseSpec(this.spec); parts.forEach(function (part) { - if (part[0] === '%') { + if (part[0] === '%' && part.length > 1) { vNames.push(part.slice(1)); } }); |
