Skip to content

Commit 7f9b38f

Browse files
committed
search better
1 parent e68c5d7 commit 7f9b38f

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

helpers.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,3 +137,10 @@ func Substring(str string, length int) string {
137137
}
138138
return str
139139
}
140+
141+
func TSVSearch(str string) string {
142+
if str == "" {
143+
return str
144+
}
145+
return strings.Join(strings.Split(str, " "), ":* & ") + ":*"
146+
}

0 commit comments

Comments
 (0)