mirror of
https://github.com/Readarr/Readarr
synced 2026-02-02 21:03:00 +01:00
Add forceSave to the OpenAPI docs
(cherry picked from commit ef0b91b45bc7f1295efb03dc44630f1442e18be1) Fixes #2504
This commit is contained in:
parent
e6da9d26fd
commit
751ade0338
1 changed files with 1 additions and 3 deletions
|
|
@ -7,7 +7,6 @@
|
|||
using NzbDrone.Core.ThingiProvider;
|
||||
using NzbDrone.Core.Validation;
|
||||
using NzbDrone.Http.REST.Attributes;
|
||||
using Readarr.Http.Extensions;
|
||||
using Readarr.Http.REST;
|
||||
|
||||
namespace Readarr.Api.V1
|
||||
|
|
@ -74,10 +73,9 @@ public ActionResult<TProviderResource> CreateProvider(TProviderResource provider
|
|||
}
|
||||
|
||||
[RestPutById]
|
||||
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 forceSave = Request.GetBooleanQueryParameter("forceSave");
|
||||
|
||||
// Only test existing definitions if it is enabled and forceSave isn't set.
|
||||
if (providerDefinition.Enable && !forceSave)
|
||||
|
|
|
|||
Loading…
Reference in a new issue