mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2026-09-20 00:30:43 +00:00
Extend the enlist operator to optionally not de-duplicate
This commit is contained in:
@@ -16,7 +16,16 @@ Filter operator returning its operand parsed as a list
|
||||
Export our filter function
|
||||
*/
|
||||
exports.enlist = function(source,operator,options) {
|
||||
var list = $tw.utils.parseStringArray(operator.operand);
|
||||
var allowDuplicates = false;
|
||||
switch(operator.suffix) {
|
||||
case "raw":
|
||||
allowDuplicates = true;
|
||||
break;
|
||||
case "dedupe":
|
||||
allowDuplicates = false;
|
||||
break;
|
||||
}
|
||||
var list = $tw.utils.parseStringArray(operator.operand,allowDuplicates);
|
||||
if(operator.prefix === "!") {
|
||||
var results = [];
|
||||
source(function(tiddler,title) {
|
||||
|
||||
Reference in New Issue
Block a user