Beispiel #1
0
        public async Task <IActionResult> FlightInvitationResponse([FromBody] InvitationResponseDTO model)
        {
            if (ModelState.IsValid)
            {
                var user = await UserService.GetCurrentUser();

                if (user != null)
                {
                    await UserService.AcceptInvitation(model.InvitationId, model.Accepted);

                    return(Ok(200));
                }
            }

            return(BadRequest("Not enough data provided."));
        }