negate operator for more queries

This commit is contained in:
Ted Unangst 2023-08-28 17:41:56 -04:00
parent 15572f2e21
commit a6bc763507
1 changed files with 2 additions and 2 deletions

View File

@ -307,11 +307,11 @@ func gethonksbysearch(userid int64, q string, wanted int64) []*Honk {
continue continue
} }
if t == "@me" { if t == "@me" {
queries = append(queries, "whofore = 1") queries = append(queries, negate+"whofore = 1")
continue continue
} }
if t == "@self" { if t == "@self" {
queries = append(queries, "(whofore = 2 or whofore = 3)") queries = append(queries, negate+"(whofore = 2 or whofore = 3)")
continue continue
} }
if strings.HasPrefix(t, "before:") { if strings.HasPrefix(t, "before:") {