-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fixes list filter #1419
fixes list filter #1419
Conversation
previously did not correctly handle / match the source but only output the list as is
replace operator.prefix throughout filters?
Yes, we should wait for those other pull requests to settle down. I'm working my way in reverse chronological order. |
I think it would be ok, to take the helper with this pull request and adapt all other filters in a later one... so as to have this issue ticked off. |
@@ -30,7 +30,8 @@ function parseFilterOperation(operators,filterString,p) { | |||
operator = {}; | |||
// Check for an operator prefix | |||
if(filterString.charAt(p) === "!") { | |||
operator.prefix = filterString.charAt(p++); | |||
operator.prefix = filterString.charAt(p++); // remove? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why should this line be removed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for using operator.negate instead
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But there's lots of core code using operator.prefix instead, isn't there? I agree that operator.negate is better but we should apply it consistently if we're going to introduce it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes we can... one step at a time ...after all, this issue is about the list filter
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, but separation of concerns would be better if we fixed the list filter independently of introducing operator.negate. it's about having a readable commit history.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
but this is really about fixing negation and depends on that construct. I would rather not make a pull request with that function first only to use it here.
previously did not correctly handle / match the source but only output the list as is replaces TiddlyWiki#1419
closing this, because the refactoring doesn't appear to be desired (in the context of this) |
previously did not correctly handle / match the source but only output the list as is