diff options
| author | Patrick Barron <barronpm@gmail.com> | 2020-04-14 16:01:21 -0400 |
|---|---|---|
| committer | Patrick Barron <barronpm@gmail.com> | 2020-04-14 16:01:21 -0400 |
| commit | ecaae2c8de3bf03d3a74de865546dc6b14c06b12 (patch) | |
| tree | e79b94be779d17a2a9a186170d326502b32fc903 | |
| parent | ddd8120aabc0754660e3f282408523932b61dd77 (diff) | |
Clean up and document ServerConfigurationManager.cs
| -rw-r--r-- | Emby.Server.Implementations/Configuration/ServerConfigurationManager.cs | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/Emby.Server.Implementations/Configuration/ServerConfigurationManager.cs b/Emby.Server.Implementations/Configuration/ServerConfigurationManager.cs index f407317ec..0ff70deca 100644 --- a/Emby.Server.Implementations/Configuration/ServerConfigurationManager.cs +++ b/Emby.Server.Implementations/Configuration/ServerConfigurationManager.cs @@ -69,21 +69,16 @@ namespace Emby.Server.Implementations.Configuration /// </summary> private void UpdateMetadataPath() { - if (string.IsNullOrWhiteSpace(Configuration.MetadataPath)) - { - ((ServerApplicationPaths)ApplicationPaths).InternalMetadataPath = Path.Combine(ApplicationPaths.ProgramDataPath, "metadata"); - } - else - { - ((ServerApplicationPaths)ApplicationPaths).InternalMetadataPath = Configuration.MetadataPath; - } + ((ServerApplicationPaths)ApplicationPaths).InternalMetadataPath = string.IsNullOrWhiteSpace(Configuration.MetadataPath) + ? Path.Combine(ApplicationPaths.ProgramDataPath, "metadata") + : Configuration.MetadataPath; } /// <summary> /// Replaces the configuration. /// </summary> /// <param name="newConfiguration">The new configuration.</param> - /// <exception cref="DirectoryNotFoundException"></exception> + /// <exception cref="DirectoryNotFoundException">If the configuration path doesn't exist.</exception> public override void ReplaceConfiguration(BaseApplicationConfiguration newConfiguration) { var newConfig = (ServerConfiguration)newConfiguration; |
