From 04d1a53d199bbf5fced102daae77b3ef0d64474d Mon Sep 17 00:00:00 2001 From: Luke Pulverenti Date: Sun, 29 Dec 2013 12:07:29 -0500 Subject: don't persist lazy loaded paths --- MediaBrowser.Common.Implementations/BaseApplicationPaths.cs | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) (limited to 'MediaBrowser.Common.Implementations/BaseApplicationPaths.cs') diff --git a/MediaBrowser.Common.Implementations/BaseApplicationPaths.cs b/MediaBrowser.Common.Implementations/BaseApplicationPaths.cs index 213942c9d..668b1395d 100644 --- a/MediaBrowser.Common.Implementations/BaseApplicationPaths.cs +++ b/MediaBrowser.Common.Implementations/BaseApplicationPaths.cs @@ -140,10 +140,6 @@ namespace MediaBrowser.Common.Implementations } } - /// - /// The _configuration directory path - /// - private string _configurationDirectoryPath; /// /// Gets the path to the application configuration root directory /// @@ -152,12 +148,7 @@ namespace MediaBrowser.Common.Implementations { get { - if (_configurationDirectoryPath == null) - { - _configurationDirectoryPath = Path.Combine(ProgramDataPath, "config"); - Directory.CreateDirectory(_configurationDirectoryPath); - } - return _configurationDirectoryPath; + return Path.Combine(ProgramDataPath, "config"); } } @@ -218,7 +209,7 @@ namespace MediaBrowser.Common.Implementations /// System.String. private string GetProgramDataPath() { - var programDataPath = _useDebugPath ? ConfigurationManager.AppSettings["DebugProgramDataPath"] : Path.Combine(ConfigurationManager.AppSettings["ReleaseProgramDataPath"], ConfigurationManager.AppSettings["ProgramDataFolderName"]); + var programDataPath = _useDebugPath ? ConfigurationManager.AppSettings["DebugProgramDataPath"] : ConfigurationManager.AppSettings["ReleaseProgramDataPath"]; programDataPath = programDataPath.Replace("%ApplicationData%", Environment.GetFolderPath(Environment.SpecialFolder.ApplicationData)); -- cgit v1.2.3