Skip to content

Commit

Permalink
修复搜索符号 ' 会闪退的问题。
Browse files Browse the repository at this point in the history
close: #264
  • Loading branch information
Finb committed Dec 11, 2024
1 parent 4a2bf08 commit 3de149c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Controller/MessageListViewModel.swift
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class MessageListViewModel: ViewModel, ViewModelType {
results = results.filter("group in %@", filterGroups)
}
if let text = searchText, text.count > 0 {
results = results.filter("title contains[c] '\(text)' or body contains[c] '\(text)'")
results = results.filter("title CONTAINS[c] %@ OR body CONTAINS[c] %@", text, text)
}
return results
}
Expand Down

0 comments on commit 3de149c

Please sign in to comment.