From acd93c42d8a6385a05067ce7b4baaeaa2f85b338 Mon Sep 17 00:00:00 2001 From: JP Dillingham Date: Sat, 31 Jul 2021 17:41:31 -0500 Subject: tweak some config items for consistency --- .../Application/Management/API/Controllers/SessionController.cs | 2 +- src/slskd/Common/Configuration/DefaultValueConfigurationSource.cs | 2 +- src/slskd/Options.cs | 6 +++--- src/slskd/Startup.cs | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) (limited to 'src') diff --git a/src/slskd/Application/Management/API/Controllers/SessionController.cs b/src/slskd/Application/Management/API/Controllers/SessionController.cs index 02e8257e..a9ae0188 100644 --- a/src/slskd/Application/Management/API/Controllers/SessionController.cs +++ b/src/slskd/Application/Management/API/Controllers/SessionController.cs @@ -80,7 +80,7 @@ namespace slskd.Management.API [ProducesResponseType(typeof(bool), 200)] public IActionResult Enabled() { - return Ok(!OptionsAtStartup.Web.Authentication.Disable); + return Ok(!OptionsAtStartup.Web.Authentication.Disabled); } /// diff --git a/src/slskd/Common/Configuration/DefaultValueConfigurationSource.cs b/src/slskd/Common/Configuration/DefaultValueConfigurationSource.cs index a13850dc..8cf62e91 100644 --- a/src/slskd/Common/Configuration/DefaultValueConfigurationSource.cs +++ b/src/slskd/Common/Configuration/DefaultValueConfigurationSource.cs @@ -114,7 +114,7 @@ namespace slskd.Configuration else { // serialize array defaults and stick them on the parent key - // (not indexed by array position). this value is "stuck", and + // (not indexed by array position). this value is "stuck", and // we want to show that in the config debug view. this isn't really // functional, just illustrative. Data[key] = JsonSerializer.Serialize(property.GetValue(defaults)); diff --git a/src/slskd/Options.cs b/src/slskd/Options.cs index c9a107cc..ff791f39 100644 --- a/src/slskd/Options.cs +++ b/src/slskd/Options.cs @@ -562,7 +562,7 @@ namespace slskd [EnvironmentVariable("NO_AUTH")] [Description("disable authentication for web requests")] [RequiresRestart] - public bool Disable { get; private set; } = false; + public bool Disabled { get; private set; } = false; /// /// Gets the username for the web UI. @@ -701,7 +701,7 @@ namespace slskd /// Gets a value indicating whether the FTP integration is enabled. /// [Argument(default, "ftp")] - [EnvironmentVariable("FTP_ENABLED")] + [EnvironmentVariable("FTP")] [Description("enable FTP integration")] public bool Enabled { get; private set; } @@ -816,7 +816,7 @@ namespace slskd /// Gets a value indicating whether the Pushbullet integration is enabled. /// [Argument(default, "pushbullet")] - [EnvironmentVariable("PUSHBULLET_ENABLED")] + [EnvironmentVariable("PUSHBULLET")] [Description("enable Pushbullet integration")] public bool Enabled { get; private set; } = false; diff --git a/src/slskd/Startup.cs b/src/slskd/Startup.cs index af0fd329..dcbf0a16 100644 --- a/src/slskd/Startup.cs +++ b/src/slskd/Startup.cs @@ -112,7 +112,7 @@ namespace slskd services.AddSingleton(JwtSigningKey); - if (!OptionsAtStartup.Web.Authentication.Disable) + if (!OptionsAtStartup.Web.Authentication.Disabled) { services.AddAuthentication(JwtBearerDefaults.AuthenticationScheme) .AddJwtBearer(options => -- cgit v1.2.3