Skip to content

Commit

Permalink
Search: Add "at" as an alias for "and" #22
Browse files Browse the repository at this point in the history
  • Loading branch information
lastzero committed Sep 6, 2021
1 parent d51aa86 commit 6d30419
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions internal/query/like.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ func NormalizeSearchQuery(s string) string {
s = strings.ReplaceAll(s, AndEn, And)
s = strings.ReplaceAll(s, WithEn, And)
s = strings.ReplaceAll(s, InEn, And)
s = strings.ReplaceAll(s, AtEn, And)
s = strings.ReplaceAll(s, Plus, And)
s = strings.ReplaceAll(s, "%", "*")
return strings.Trim(s, "+&|_-=!@$%^(){}\\<>,.;: ")
Expand Down
1 change: 1 addition & 0 deletions internal/query/query.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ const (
AndEn = " and "
WithEn = " with "
InEn = " in "
AtEn = " at "
Space = " "
Empty = ""
)
Expand Down

0 comments on commit 6d30419

Please sign in to comment.