diff options
| author | BaronGreenback <jimcartlidge@yahoo.co.uk> | 2020-12-18 23:55:23 +0000 |
|---|---|---|
| committer | BaronGreenback <jimcartlidge@yahoo.co.uk> | 2020-12-18 23:55:23 +0000 |
| commit | 46c7499e2b6e5897caeb562d4c0eba89aed843f2 (patch) | |
| tree | d0e843d4fd54e9badbb53a15059247cc810881cd | |
| parent | bae8f0c4ec4a123db573579d09bf9051e84d3911 (diff) | |
reverted change
| -rw-r--r-- | MediaBrowser.Common/Plugins/BasePluginOfT.cs | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/MediaBrowser.Common/Plugins/BasePluginOfT.cs b/MediaBrowser.Common/Plugins/BasePluginOfT.cs index 24a6dbeac..ea05a722b 100644 --- a/MediaBrowser.Common/Plugins/BasePluginOfT.cs +++ b/MediaBrowser.Common/Plugins/BasePluginOfT.cs @@ -15,8 +15,6 @@ namespace MediaBrowser.Common.Plugins public abstract class BasePlugin<TConfigurationType> : BasePlugin, IHasPluginConfiguration where TConfigurationType : BasePluginConfiguration { - private readonly string _dataFolderPath; - /// <summary> /// The configuration sync lock. /// </summary> @@ -49,14 +47,14 @@ namespace MediaBrowser.Common.Plugins var assemblyName = assembly.GetName(); var assemblyFilePath = assembly.Location; - _dataFolderPath = Path.Combine(ApplicationPaths.PluginsPath, Path.GetFileNameWithoutExtension(assemblyFilePath)); - if (!Directory.Exists(_dataFolderPath) && Version != null) + var dataFolderPath = Path.Combine(ApplicationPaths.PluginsPath, Path.GetFileNameWithoutExtension(assemblyFilePath)); + if (!Directory.Exists(dataFolderPath) && Version != null) { // Try again with the version number appended to the folder name. - _dataFolderPath = _dataFolderPath + "_" + Version.ToString(); + dataFolderPath = dataFolderPath + "_" + Version.ToString(); } - assemblyPlugin.SetAttributes(assemblyFilePath, _dataFolderPath, assemblyName.Version); + assemblyPlugin.SetAttributes(assemblyFilePath, dataFolderPath, assemblyName.Version); var idAttributes = assembly.GetCustomAttributes(typeof(GuidAttribute), true); if (idAttributes.Length > 0) @@ -139,7 +137,7 @@ namespace MediaBrowser.Common.Plugins /// Gets the full path to the configuration file. /// </summary> /// <value>The configuration file path.</value> - public string ConfigurationFilePath => Path.Combine(_dataFolderPath, ConfigurationFileName); + public string ConfigurationFilePath => Path.Combine(ApplicationPaths.PluginConfigurationsPath, ConfigurationFileName); /// <summary> /// Gets the plugin configuration. |
