diff --git a/core/modules/widgets/widget.js b/core/modules/widgets/widget.js index e6232928de..d96104b2e5 100755 --- a/core/modules/widgets/widget.js +++ b/core/modules/widgets/widget.js @@ -390,7 +390,7 @@ Widget.prototype.computeAttributes = function(options) { if($tw.utils.isArray(value)) { multiValue = value; newMultiValuedAttributes[name] = multiValue; - value = value[0] || ""; + value = value[0]; } var changed = (self.attributes[name] !== value); if(!changed && multiValue && self.multiValuedAttributes) { diff --git a/editions/test/tiddlers/tests/data/transclude/MissingTiddlerAttribute.tid b/editions/test/tiddlers/tests/data/transclude/MissingTiddlerAttribute.tid new file mode 100644 index 0000000000..8cce08671a --- /dev/null +++ b/editions/test/tiddlers/tests/data/transclude/MissingTiddlerAttribute.tid @@ -0,0 +1,39 @@ +title: Transclude/MissingTiddlerAttribute +description: Missing Tiddler Attribute +type: text/vnd.tiddlywiki-multiple +tags: [[$:/tags/wiki-test-spec]] + +title: Output + +\procedure testproc() +This is ''wikitext'' +\end + + +<$tiddler tiddler="Data"> +<$transclude $index="testindex"/> +- +{{##testindex}} +- +<$transclude $field="custom"/> +- +{{!!custom}} + ++ +title: Data +type: application/x-tiddler-dictionary +custom: This is ''wikitext'' + +testindex: This is ''wikitext'' ++ +title: ExpectedResult + +

+This is wikitext +- +This is wikitext +- +This is wikitext +- +This is wikitext +

\ No newline at end of file