allow separate configuration of app resources path

This commit is contained in:
Luke Pulverenti
2014-11-26 15:57:16 -05:00
parent 17081767da
commit 63a0d52fd1
7 changed files with 25 additions and 29 deletions

View File

@@ -153,16 +153,18 @@ namespace MediaBrowser.ServerApplication
/// <returns>ServerApplicationPaths.</returns>
private static ServerApplicationPaths CreateApplicationPaths(string applicationPath, bool runAsService)
{
var resourcesPath = Path.GetDirectoryName(applicationPath);
if (runAsService)
{
var systemPath = Path.GetDirectoryName(applicationPath);
var programDataPath = Path.GetDirectoryName(systemPath);
return new ServerApplicationPaths(programDataPath, applicationPath);
return new ServerApplicationPaths(programDataPath, applicationPath, resourcesPath);
}
return new ServerApplicationPaths(ApplicationPathHelper.GetProgramDataPath(applicationPath), applicationPath);
return new ServerApplicationPaths(ApplicationPathHelper.GetProgramDataPath(applicationPath), applicationPath, resourcesPath);
}
/// <summary>