Changes to support network config

This commit is contained in:
Greenback
2020-10-10 14:05:19 +01:00
parent ebe650afa9
commit 6dc81ec8e8
5 changed files with 51 additions and 28 deletions

View File

@@ -51,10 +51,6 @@ namespace Jellyfin.Api.Controllers
[ProducesResponseType(StatusCodes.Status200OK)]
public ActionResult<ServerConfiguration> GetConfiguration()
{
// TODO: Temp workaround until the web can be changed.
var net = _configurationManager.GetNetworkConfiguration();
ClassMigrationHelper.CopyProperties(net, _configurationManager.Configuration);
return _configurationManager.Configuration;
}
@@ -70,12 +66,6 @@ namespace Jellyfin.Api.Controllers
public ActionResult UpdateConfiguration([FromBody, Required] ServerConfiguration configuration)
{
_configurationManager.ReplaceConfiguration(configuration);
// TODO: Temp workaround until the web can be changed.
var network = _configurationManager.GetNetworkConfiguration();
ClassMigrationHelper.CopyProperties(configuration, network);
_configurationManager.SaveConfiguration("Network", network);
return NoContent();
}