mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-04-17 15:53:42 +01:00
fixed plugin assembly downloads as well as debug/release detection with nuget assemblies
This commit is contained in:
@@ -12,6 +12,20 @@ namespace MediaBrowser.Common.Implementations
|
||||
/// </summary>
|
||||
public abstract class BaseApplicationPaths : IApplicationPaths
|
||||
{
|
||||
/// <summary>
|
||||
/// The _use debug path
|
||||
/// </summary>
|
||||
private bool _useDebugPath;
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="BaseApplicationPaths" /> class.
|
||||
/// </summary>
|
||||
/// <param name="useDebugPath">if set to <c>true</c> [use debug paths].</param>
|
||||
protected BaseApplicationPaths(bool useDebugPath)
|
||||
{
|
||||
_useDebugPath = useDebugPath;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// The _program data path
|
||||
/// </summary>
|
||||
@@ -272,14 +286,9 @@ namespace MediaBrowser.Common.Implementations
|
||||
/// Gets the path to the application's ProgramDataFolder
|
||||
/// </summary>
|
||||
/// <returns>System.String.</returns>
|
||||
public static string GetProgramDataPath()
|
||||
private string GetProgramDataPath()
|
||||
{
|
||||
#if DEBUG
|
||||
string programDataPath = ConfigurationManager.AppSettings["DebugProgramDataPath"];
|
||||
|
||||
#else
|
||||
string programDataPath = Path.Combine(ConfigurationManager.AppSettings["ReleaseProgramDataPath"], ConfigurationManager.AppSettings["ProgramDataFolderName"]);
|
||||
#endif
|
||||
var programDataPath = _useDebugPath ? ConfigurationManager.AppSettings["DebugProgramDataPath"] : Path.Combine(ConfigurationManager.AppSettings["ReleaseProgramDataPath"], ConfigurationManager.AppSettings["ProgramDataFolderName"]);
|
||||
|
||||
programDataPath = programDataPath.Replace("%CommonApplicationData%", Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user