aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Monteiro <marknr.monteiro@protonmail.com>2020-03-17 14:19:43 +0100
committerMark Monteiro <marknr.monteiro@protonmail.com>2020-03-17 14:19:43 +0100
commit7dd2f3a8f2dc6ea4db5ef9e1db4684b39cbcb6d3 (patch)
tree1c775ec518e71b3639934adfc13a74cb3b047031
parent48ea7dc6046392356347a433a436cfd04b5e3f29 (diff)
Do not add command line flag to the config hierarchy unless it is explicitly set
-rw-r--r--Jellyfin.Server/StartupOptions.cs12
1 files changed, 9 insertions, 3 deletions
diff --git a/Jellyfin.Server/StartupOptions.cs b/Jellyfin.Server/StartupOptions.cs
index ac5df3925..0abc0fd91 100644
--- a/Jellyfin.Server/StartupOptions.cs
+++ b/Jellyfin.Server/StartupOptions.cs
@@ -81,9 +81,15 @@ namespace Jellyfin.Server
/// </summary>
/// <returns>The configuration dictionary.</returns>
public Dictionary<string, string> ConvertToConfig()
- => new Dictionary<string, string>
+ {
+ var config = new Dictionary<string, string>();
+
+ if (NoWebContent)
{
- { ConfigurationExtensions.NoWebContentKey, NoWebContent.ToString(CultureInfo.InvariantCulture) }
- };
+ config.Add(ConfigurationExtensions.NoWebContentKey, bool.TrueString);
+ }
+
+ return config;
+ }
}
}