mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-01-23 07:26:54 +00:00
Change the search filter operator to not indirect through a tiddler
Now that we can make any filter operator indirect through a tiddler we don't need to have that as a special capability of the search operator.
This commit is contained in:
parent
f4a3b25d3e
commit
887d955fc4
@ -1,5 +1,5 @@
|
||||
/*\
|
||||
title: $:/core/modules/filters/searchVia.js
|
||||
title: $:/core/modules/filters/search.js
|
||||
type: application/javascript
|
||||
module-type: filteroperator
|
||||
|
||||
@ -15,10 +15,9 @@ Filter operator for searching for the text in the operand tiddler
|
||||
/*
|
||||
Export our filter function
|
||||
*/
|
||||
exports.searchVia = function(source,operator,options) {
|
||||
var term = options.wiki.getTiddlerText(operator.operand,""),
|
||||
invert = operator.prefix === "!";
|
||||
return options.wiki.search(term,{
|
||||
exports.search = function(source,operator,options) {
|
||||
var invert = operator.prefix === "!";
|
||||
return options.wiki.search(operator.operand,{
|
||||
titles: source,
|
||||
invert: invert,
|
||||
exclude: [operator.operand]
|
Loading…
Reference in New Issue
Block a user