mirror of
https://github.com/Prowlarr/Prowlarr
synced 2025-12-15 21:14:32 +01:00
Add forceSave to the OpenAPI docs (#1670)
This commit is contained in:
parent
4a5a986220
commit
2b0f4e18e7
1 changed files with 1 additions and 3 deletions
|
|
@ -6,7 +6,6 @@
|
|||
using NzbDrone.Core.ThingiProvider;
|
||||
using NzbDrone.Core.Validation;
|
||||
using NzbDrone.Http.REST.Attributes;
|
||||
using Prowlarr.Http.Extensions;
|
||||
using Prowlarr.Http.REST;
|
||||
|
||||
namespace Prowlarr.Api.V1
|
||||
|
|
@ -76,10 +75,9 @@ public ActionResult<TProviderResource> CreateProvider(TProviderResource provider
|
|||
|
||||
[RestPutById]
|
||||
[Produces("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 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