< Summary

Information
Class: Syki.Back.Features.Cross.GetMfaKey.GetMfaKeyController
Assembly: Back
File(s): /home/runner/work/syki/syki/Back/Features/Cross/GetMfaKey/GetMfaKeyController.cs
Tag: 22_11348620282
Line coverage
100%
Covered lines: 4
Uncovered lines: 0
Coverable lines: 4
Total lines: 21
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
.ctor(...)100%11100%
Get()100%11100%

File(s)

/home/runner/work/syki/syki/Back/Features/Cross/GetMfaKey/GetMfaKeyController.cs

#LineLine coverage
 1namespace Syki.Back.Features.Cross.GetMfaKey;
 2
 3/// <summary>
 4/// Retorna a chave MFA do usuário.
 5/// Ela é mostrada em tela via QR-Code.
 6/// </summary>
 7[ApiController, AuthBearer]
 8[EnableRateLimiting("Small")]
 9[Consumes("application/json"), Produces("application/json")]
 910public class GetMfaKeyController(GetMfaKeyService service) : ControllerBase
 11{
 12    [HttpGet("mfa/key")]
 13    [ProducesResponseType(200)]
 14    [SwaggerResponseExample(200, typeof(GetMfaKeyResponseExamples))]
 15    public async Task<IActionResult> Get()
 16    {
 917        var key = await service.Get(User.Id());
 18
 919        return Ok(key);
 920    }
 21}