public IActionResult LoginCashier([FromBody] Cashier cashier) { try { var userAuthorized = _cashierRepository.AuthorizeUser(cashier.Username, cashier.Password); return(Ok(new { id = userAuthorized.Id, username = userAuthorized.Username, token = _jwtHelper.GetJwtToken(userAuthorized) })); } catch (Exception) { return(ValidationProblem()); } }