mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-16 10:03:51 -07:00
Removed tvdblib from tests
Added settings to API
This commit is contained in:
parent
77eedf448e
commit
c5b845cbee
16 changed files with 32 additions and 50 deletions
25
NzbDrone.Api/Settings/SettingsModule.cs
Normal file
25
NzbDrone.Api/Settings/SettingsModule.cs
Normal file
|
@ -0,0 +1,25 @@
|
|||
using System.Linq;
|
||||
using Nancy;
|
||||
using NzbDrone.Api.Extensions;
|
||||
using NzbDrone.Core.Configuration;
|
||||
|
||||
namespace NzbDrone.Api.Settings
|
||||
{
|
||||
public class SettingsModule : NzbDroneApiModule
|
||||
{
|
||||
private readonly ConfigService _configService;
|
||||
|
||||
public SettingsModule(ConfigService configService)
|
||||
: base("/settings")
|
||||
{
|
||||
_configService = configService;
|
||||
Get["/"] = x => GetAllSettings();
|
||||
}
|
||||
|
||||
private Response GetAllSettings()
|
||||
{
|
||||
var settings = _configService.All();
|
||||
return settings.AsResponse();
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue