diff --git a/core/modules/wiki.js b/core/modules/wiki.js index 9fd254be9..2eeacb920 100755 --- a/core/modules/wiki.js +++ b/core/modules/wiki.js @@ -1075,20 +1075,9 @@ exports.makeWidget = function(parser,options) { options = options || {}; var widgetNode = { type: "widget", - children: [{ - type: "importvariables", - attributes: { - filter: { - name: "filter", - type: "string", - value: "[all[shadows+tiddlers]tag[$:/tags/Global]!is[draft]]" - } - }, - isBlock: false, - children: [] - }] + children: [] }, - currWidgetNode = widgetNode.children[0]; + currWidgetNode = widgetNode; // Create let variable widget for variables if($tw.utils.count(options.variables) > 0) { var letVariableWidget = { @@ -1098,14 +1087,10 @@ exports.makeWidget = function(parser,options) { children: [] }; $tw.utils.each(options.variables,function(value,name) { - letVariableWidget.attributes[name] = { - name: name, - type: "string", - value: "" + value - } + $tw.utils.addAttributeToParseTreeNode(letVariableWidget,name,"" + value); }); currWidgetNode.children = [letVariableWidget]; - currWidgetNode = letVariableWidget; + currWidgetNode = letVariableWidget.children[0]; } // Add in the supplied parse tree nodes currWidgetNode.children = parser ? parser.tree : []; diff --git a/editions/test/tiddlers/tests/data/globals/Simple.tid b/editions/test/tiddlers/tests/data/globals/Simple.tid deleted file mode 100644 index 6e4d0fc06..000000000 --- a/editions/test/tiddlers/tests/data/globals/Simple.tid +++ /dev/null @@ -1,19 +0,0 @@ -title: Globals/Simple -description: Global procedures -type: text/vnd.tiddlywiki-multiple -tags: [[$:/tags/wiki-test-spec]] - -title: Output - -\whitespace trim - -<> -+ -title: One -tags: $:/tags/Global - -\procedure this-is-one() ONE -+ -title: ExpectedResult - -

ONE

\ No newline at end of file