mirror of https://github.com/Sonarr/Sonarr
Fixed: Case insensitive paths for static resources under Windows
Fixes #2157
This commit is contained in:
parent
9c1d275403
commit
50b01d8d00
|
@ -1,4 +1,4 @@
|
||||||
using System;
|
using System;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using NLog;
|
using NLog;
|
||||||
using Nancy;
|
using Nancy;
|
||||||
|
@ -21,10 +21,7 @@ namespace NzbDrone.Api.Frontend.Mappers
|
||||||
_diskProvider = diskProvider;
|
_diskProvider = diskProvider;
|
||||||
_logger = logger;
|
_logger = logger;
|
||||||
|
|
||||||
if (!RuntimeInfo.IsProduction)
|
_caseSensitive = RuntimeInfo.IsProduction ? DiskProviderBase.PathStringComparison : StringComparison.OrdinalIgnoreCase;
|
||||||
{
|
|
||||||
_caseSensitive = StringComparison.OrdinalIgnoreCase;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public abstract string Map(string resourceUrl);
|
public abstract string Map(string resourceUrl);
|
||||||
|
@ -50,6 +47,5 @@ namespace NzbDrone.Api.Frontend.Mappers
|
||||||
{
|
{
|
||||||
return File.OpenRead(filePath);
|
return File.OpenRead(filePath);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue