Skip to content

Commit

Permalink
Merge pull request #934 from rwf-rr/fix-contentmanager-search-bug-194…
Browse files Browse the repository at this point in the history
…4070

Fix bug 1944070: ContentManager search exception.
  • Loading branch information
twpol committed Apr 25, 2024
2 parents 6ac96f9 + 6573b5f commit 1ab6b90
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Source/Contrib/ContentManager/ContentManagerGUI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,8 @@ void searchBox_TextChanged(object sender, EventArgs e)
var content = pending[path];
pending.Remove(path);
if (content.Name.ToLowerInvariant().Contains(search))
// do not add root element to search results, see bug 1944070
if (content.Type != ContentType.Root && content.Name.ToLowerInvariant().Contains(search))
finds.Add(new SearchResult(content, path));
foreach (var child in ((ContentType[])Enum.GetValues(typeof(ContentType))).SelectMany(ct => content.Get(ct)))
Expand Down

0 comments on commit 1ab6b90

Please sign in to comment.