1
0
Fork 0
mirror of https://github.com/lidarr/Lidarr synced 2024-12-25 09:12:17 +00:00

Fixed: Case insensitive paths for static resources under Windows

This commit is contained in:
Qstick 2017-10-29 21:26:22 -04:00
parent d3aa032cf5
commit a1bf1b99f5

View file

@ -1,4 +1,4 @@
using System;
using System;
using System.IO;
using Nancy;
using Nancy.Responses;
@ -21,10 +21,7 @@ protected StaticResourceMapperBase(IDiskProvider diskProvider, Logger logger)
_diskProvider = diskProvider;
_logger = logger;
if (!RuntimeInfo.IsProduction)
{
_caseSensitive = StringComparison.OrdinalIgnoreCase;
}
_caseSensitive = RuntimeInfo.IsProduction ? DiskProviderBase.PathStringComparison : StringComparison.OrdinalIgnoreCase;
}
public abstract string Map(string resourceUrl);
@ -52,4 +49,4 @@ protected virtual Stream GetContentStream(string filePath)
}
}
}
}