- 
                Notifications
    You must be signed in to change notification settings 
- Fork 1.3k
Allow short search strings on new workspace page #20415
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 3 commits
4896f98
              0147dd7
              c50559b
              89221af
              3dcba47
              b029dd5
              File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | 
|---|---|---|
|  | @@ -62,7 +62,7 @@ export const useUnifiedRepositorySearch = ({ | |
| }, [configurationSearch.data, excludeConfigurations]); | ||
|  | ||
| const filteredRepos = useMemo(() => { | ||
| const repos = [suggestedQuery.data || [], searchQuery.data || [], flattenedConfigurations ?? []].flat(); | ||
| const repos = [suggestedQuery.data || [], flattenedConfigurations ?? [], searchQuery.data || []].flat(); | ||
| There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is done to artificially boost the priority of imported repos vs SCM-provided results. Every time I change this, I think about how much we need to get rid of it entirely and just let  | ||
| return deduplicateAndFilterRepositories(searchString, excludeConfigurations, onlyConfigurations, repos); | ||
| }, [ | ||
| searchString, | ||
|  | @@ -113,7 +113,7 @@ export function deduplicateAndFilterRepositories( | |
| } | ||
|  | ||
| // filter out entries that don't match the search string | ||
| if (!`${repo.url}${repo.configurationName || ""}`.toLowerCase().includes(searchString.trim().toLowerCase())) { | ||
| if (!`${repo.url}${repo.configurationName ?? ""}`.toLowerCase().includes(searchString.trim().toLowerCase())) { | ||
| continue; | ||
| } | ||
| // filter out duplicates | ||
|  | ||
Uh oh!
There was an error while loading. Please reload this page.