Skip to content
This repository was archived by the owner on Sep 20, 2023. It is now read-only.

Commit 518824f

Browse files
authored
add space to default search string (#1750)
1 parent 79f4ac9 commit 518824f

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

Classes/Repository/RepositoryIssuesViewController.swift

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ SearchBarSectionControllerDelegate {
2424
private let type: RepositoryIssuesType
2525
private let searchKey: ListDiffable = "searchKey" as ListDiffable
2626
private let debouncer = Debouncer()
27-
private var previousSearchString = "is:open"
27+
private var previousSearchString = "is:open "
2828

2929
init(client: GithubClient, repo: RepositoryDetails, type: RepositoryIssuesType) {
3030
self.repo = repo
@@ -81,9 +81,8 @@ SearchBarSectionControllerDelegate {
8181
// MARK: SearchBarSectionControllerDelegate
8282

8383
func didChangeSelection(sectionController: SearchBarSectionController, query: String) {
84-
let trimmed = query.trimmingCharacters(in: .whitespacesAndNewlines)
85-
guard previousSearchString != trimmed else { return }
86-
previousSearchString = trimmed
84+
guard previousSearchString != query else { return }
85+
previousSearchString = query
8786
debouncer.action = { [weak self] in self?.fetch(page: nil) }
8887
}
8988

0 commit comments

Comments
 (0)