This commit is contained in:
Flaminel
2025-05-15 19:34:12 +03:00
parent 6eb457ed8f
commit b6950f545f
15 changed files with 827 additions and 153 deletions

View File

@@ -178,6 +178,9 @@ public class ConfigurationController : ControllerBase
{
try
{
// Validate the configuration
config.Validate();
// Persist the configuration
var result = await _configService.UpdateDownloadClientConfigAsync(config);
if (!result)
@@ -190,8 +193,8 @@ public class ConfigurationController : ControllerBase
}
catch (Exception ex)
{
_logger.LogError(ex, "Error updating DownloadClient configuration");
return StatusCode(500, "An error occurred while updating DownloadClient configuration");
_logger.LogError(ex, "Error updating DownloadClient configuration: {Message}", ex.Message);
return BadRequest(new { Error = ex.Message });
}
}