mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-09-10 14:56:06 +00:00
refactor: use LinkedList in transcludes[] and backtranscludes[]
This commit is contained in:
@@ -16,11 +16,11 @@ Filter operator for returning all the backtranscludes from a tiddler
|
||||
Export our filter function
|
||||
*/
|
||||
exports.backtranscludes = function(source,operator,options) {
|
||||
var results = [];
|
||||
var results = new $tw.utils.LinkedList();
|
||||
source(function(tiddler,title) {
|
||||
$tw.utils.pushTop(results,options.wiki.getTiddlerBacktranscludes(title));
|
||||
results.pushTop(options.wiki.getTiddlerBacktranscludes(title));
|
||||
});
|
||||
return results;
|
||||
return results.makeTiddlerIterator(options.wiki);
|
||||
};
|
||||
|
||||
})();
|
||||
|
@@ -20,7 +20,7 @@ exports.transcludes = function(source,operator,options) {
|
||||
source(function(tiddler,title) {
|
||||
results.pushTop(options.wiki.getTiddlerTranscludes(title));
|
||||
});
|
||||
return results.toArray();
|
||||
return results.makeTiddlerIterator(options.wiki);
|
||||
};
|
||||
|
||||
})();
|
||||
|
Reference in New Issue
Block a user