aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorebr11 Eric Reed spam <ebr11 Eric Reed spam@reedsplace.com>2012-08-04 13:10:37 -0400
committerebr11 Eric Reed spam <ebr11 Eric Reed spam@reedsplace.com>2012-08-04 13:10:37 -0400
commit9b20718e2fbdf63b00cfb2c995966cdad006891b (patch)
treeb7cdd6a4b1db71eb1600f5326dc702e31611d13b
parent3b97795b884c9bbac66efa63ff57133e567cd15b (diff)
add IBNPath and fix disastrous typos that would cause infinite loops
-rw-r--r--MediaBrowser.Common/Configuration/ApplicationPaths.cs29
1 files changed, 25 insertions, 4 deletions
diff --git a/MediaBrowser.Common/Configuration/ApplicationPaths.cs b/MediaBrowser.Common/Configuration/ApplicationPaths.cs
index 7fb1684d1..f24111025 100644
--- a/MediaBrowser.Common/Configuration/ApplicationPaths.cs
+++ b/MediaBrowser.Common/Configuration/ApplicationPaths.cs
@@ -41,9 +41,9 @@ namespace MediaBrowser.Common.Configuration
if (_pluginsPath == null)
{
_pluginsPath = Path.Combine(ProgramDataPath, "plugins");
- if (!Directory.Exists(PluginsPath))
+ if (!Directory.Exists(_configurationPath))
{
- Directory.CreateDirectory(PluginsPath);
+ Directory.CreateDirectory(_configurationPath);
}
}
@@ -62,9 +62,9 @@ namespace MediaBrowser.Common.Configuration
if (_configurationPath == null)
{
_configurationPath = Path.Combine(ProgramDataPath, "config");
- if (!Directory.Exists(ConfigurationPath))
+ if (!Directory.Exists(_configurationPath))
{
- Directory.CreateDirectory(ConfigurationPath);
+ Directory.CreateDirectory(_configurationPath);
}
}
return _configurationPath;
@@ -171,6 +171,27 @@ namespace MediaBrowser.Common.Configuration
}
}
+ private static string _ibnPath;
+ /// <summary>
+ /// Gets the path to the Images By Name directory
+ /// </summary>
+ public static string IBNPath
+ {
+ get
+ {
+ if (_ibnPath == null)
+ {
+ _ibnPath = Path.Combine(ProgramDataPath, "ImagesByName");
+ if (!Directory.Exists(_ibnPath))
+ {
+ Directory.CreateDirectory(_ibnPath);
+ }
+ }
+
+ return _pluginsPath;
+ }
+ }
+
/// <summary>
/// Gets the path to the application's ProgramDataFolder
/// </summary>