aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJP Dillingham <jp@dillingham.me>2026-10-23 10:46:20 -0500
committerJP Dillingham <jp@dillingham.me>2026-10-23 10:46:20 -0500
commit64ff7f587675b3fe04585339d33416a2d0373453 (patch)
tree3b14e96ebebabb12faf34cb082f5901a3c86e417
parent08d846f0f59a1922828504781da0612f3cfde3ab (diff)
downloadslskd-64ff7f587675b3fe04585339d33416a2d0373453.tar.gz
allow a reader to get redacted options
-rw-r--r--src/slskd/Core/API/Controllers/OptionsController.cs5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/slskd/Core/API/Controllers/OptionsController.cs b/src/slskd/Core/API/Controllers/OptionsController.cs
index e20017a8..98028c76 100644
--- a/src/slskd/Core/API/Controllers/OptionsController.cs
+++ b/src/slskd/Core/API/Controllers/OptionsController.cs
@@ -53,7 +53,6 @@ namespace slskd.Core.API
[ApiController]
[Produces("application/json")]
[Consumes("application/json")]
- [Authorize(Roles = AuthRole.AdministratorOnly)]
public class OptionsController : ControllerBase
{
public OptionsController(
@@ -76,7 +75,7 @@ namespace slskd.Core.API
/// </summary>
/// <returns></returns>
[HttpGet]
- [Authorize(Policy = AuthPolicy.Any, Roles = AuthRole.AdministratorOnly)]
+ [Authorize(Policy = AuthPolicy.Any)]
[ProducesResponseType(typeof(Options), 200)]
public IActionResult Current()
{
@@ -197,7 +196,7 @@ namespace slskd.Core.API
if (!TryValidateYaml(yaml, out var error))
{
- Log.Error(error, "Failed to validate YAML configuration");
+ Log.Error("Failed to validate YAML configuration: {Error}", error);
return BadRequest(error);
}