You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
600 B
25 lines
600 B
12 years ago
|
using System.IO;
|
||
|
using NzbDrone.Common.EnvironmentInfo;
|
||
|
|
||
|
namespace NzbDrone.Api.Frontend.Mappers
|
||
|
{
|
||
|
public class IndexHtmlMapper : IMapHttpRequestsToDisk
|
||
|
{
|
||
|
private readonly string _indexPath;
|
||
|
|
||
|
public IndexHtmlMapper(IAppFolderInfo appFolderInfo)
|
||
|
{
|
||
|
_indexPath = Path.Combine(appFolderInfo.StartUpFolder, "UI", "index.html");
|
||
|
}
|
||
|
|
||
|
public string Map(string resourceUrl)
|
||
|
{
|
||
|
return _indexPath;
|
||
|
}
|
||
|
|
||
|
public bool CanHandle(string resourceUrl)
|
||
|
{
|
||
|
return !resourceUrl.Contains(".");
|
||
|
}
|
||
|
}
|
||
|
}
|