refactor(api): Vereinfachung der GetCurrentAsync-Methode im EnvelopeController
This commit is contained in:
@@ -24,9 +24,7 @@ namespace EnvelopeGenerator.GeneratorAPI.Controllers
|
||||
{
|
||||
try
|
||||
{
|
||||
var id = User.GetId();
|
||||
|
||||
if (id is int intId)
|
||||
if (User.GetId() is int intId)
|
||||
return await _envelopeService.ReadByIdAsync(intId).ThenAsync(
|
||||
Success: Ok,
|
||||
Fail: IActionResult (msg, ntc) =>
|
||||
|
||||
Reference in New Issue
Block a user