mirror of
https://github.com/Sonarr/Sonarr
synced 2025-02-23 22:51:19 +00:00
Add forceSave
to the OpenAPI docs
This commit is contained in:
parent
b5050d02d6
commit
ef0b91b45b
1 changed files with 1 additions and 3 deletions
|
@ -6,7 +6,6 @@ using Microsoft.AspNetCore.Mvc;
|
||||||
using NzbDrone.Common.Serializer;
|
using NzbDrone.Common.Serializer;
|
||||||
using NzbDrone.Core.ThingiProvider;
|
using NzbDrone.Core.ThingiProvider;
|
||||||
using NzbDrone.Core.Validation;
|
using NzbDrone.Core.Validation;
|
||||||
using Sonarr.Http.Extensions;
|
|
||||||
using Sonarr.Http.REST;
|
using Sonarr.Http.REST;
|
||||||
using Sonarr.Http.REST.Attributes;
|
using Sonarr.Http.REST.Attributes;
|
||||||
|
|
||||||
|
@ -77,10 +76,9 @@ namespace Sonarr.Api.V3
|
||||||
|
|
||||||
[RestPutById]
|
[RestPutById]
|
||||||
[Consumes("application/json")]
|
[Consumes("application/json")]
|
||||||
public ActionResult<TProviderResource> UpdateProvider(TProviderResource providerResource)
|
public ActionResult<TProviderResource> UpdateProvider([FromBody] TProviderResource providerResource, [FromQuery] bool forceSave = false)
|
||||||
{
|
{
|
||||||
var providerDefinition = GetDefinition(providerResource, true, false, false);
|
var providerDefinition = GetDefinition(providerResource, true, false, false);
|
||||||
var forceSave = Request.GetBooleanQueryParameter("forceSave");
|
|
||||||
|
|
||||||
// Only test existing definitions if it is enabled and forceSave isn't set.
|
// Only test existing definitions if it is enabled and forceSave isn't set.
|
||||||
if (providerDefinition.Enable && !forceSave)
|
if (providerDefinition.Enable && !forceSave)
|
||||||
|
|
Loading…
Reference in a new issue