Update invoked parameter binding in Get method
The `Get` method in the `RecActionController` class was updated to use the `[FromQuery]` attribute for the `invoked` parameter. This change ensures that the parameter value is explicitly bound from the query string of the HTTP request, improving clarity and alignment with expected usage.
This commit is contained in:
parent
9d15dfe8a5
commit
77fde199e1
@ -61,7 +61,7 @@ public class RecActionController(IMediator mediator, IConfiguration config) : Co
|
||||
/// <returns>A list of RecActions for the fake profile.</returns>
|
||||
[HttpGet("fake")]
|
||||
[ProducesResponseType(StatusCodes.Status200OK)]
|
||||
public async Task<IActionResult> Get(CancellationToken cancel, bool invoked = false) => Ok(await mediator.Send(new ReadRecActionQuery()
|
||||
public async Task<IActionResult> Get(CancellationToken cancel, [FromQuery] bool invoked = false) => Ok(await mediator.Send(new ReadRecActionQuery()
|
||||
{
|
||||
ProfileId = config.GetFakeProfileId(),
|
||||
Invoked = invoked
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user