mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-07-15 10:43:30 +01:00
Code Clean up: Use Pattern Matching (#5838)
Co-authored-by: Cody Robibero <cody@robibe.ro> Co-authored-by: Patrick Barron <18354464+barronpm@users.noreply.github.com>
This commit is contained in:
@@ -354,9 +354,7 @@ namespace MediaBrowser.Controller.Entities
|
||||
|
||||
if (result.Count == 0)
|
||||
{
|
||||
var folder = LibraryManager.FindByPath(path, true) as Folder;
|
||||
|
||||
if (folder != null)
|
||||
if (LibraryManager.FindByPath(path, true) is Folder folder)
|
||||
{
|
||||
result.Add(folder);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user