Cody Robibero %!s(int64=3) %!d(string=hai) anos
pai
achega
a04f8f5efb
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      Emby.Server.Implementations/Library/PathExtensions.cs

+ 2 - 1
Emby.Server.Implementations/Library/PathExtensions.cs

@@ -40,7 +40,8 @@ namespace Emby.Server.Implementations.Library
                     && str[attributeEnd] == '=')
                 {
                     var closingIndex = str[attributeEnd..].IndexOf(']');
-                    if (closingIndex != -1)
+                    // Must be at least 1 character before the closing bracket.
+                    if (closingIndex > 1)
                     {
                         return str[(attributeEnd + 1)..(attributeEnd + closingIndex)].Trim().ToString();
                     }