mirror of
https://github.com/jellyfin/jellyfin.git
synced 2024-09-06 05:47:14 -04:00
Update ApplicationHost.cs
This commit is contained in:
parent
826148dc84
commit
92b63db569
@ -1089,8 +1089,8 @@ namespace Emby.Server.Implementations
|
|||||||
// No metafile, so lets see if the folder is versioned.
|
// No metafile, so lets see if the folder is versioned.
|
||||||
metafile = dir.Split(new[] { Path.DirectorySeparatorChar }, StringSplitOptions.RemoveEmptyEntries)[^1];
|
metafile = dir.Split(new[] { Path.DirectorySeparatorChar }, StringSplitOptions.RemoveEmptyEntries)[^1];
|
||||||
|
|
||||||
int p = dir.LastIndexOf('_');
|
int versionIndex = dir.LastIndexOf('_');
|
||||||
if (p != -1 && Version.TryParse(dir.Substring(p + 1), out Version ver))
|
if (versionIndex != -1 && Version.TryParse(dir.Substring(versionIndex + 1), out Version ver))
|
||||||
{
|
{
|
||||||
// Versioned folder.
|
// Versioned folder.
|
||||||
versions.Add((ver, metafile, dir));
|
versions.Add((ver, metafile, dir));
|
||||||
|
Loading…
Reference in New Issue
Block a user