Пример #1
0
        public IActionResult GetRideMatches([FromBody] MatchRequest model)
        {
            if (model == null)
            {
                return(BadRequest("invalid object"));
            }
            string               email   = User.FindFirst(ClaimTypes.NameIdentifier)?.Value;
            ApplicationUser      user    = context.ApplicationUsers.FirstOrDefault(c => c.Email.Equals(email));
            List <MatchResponse> Matches = IRiderService.GetMatches(user, model);

            return(Ok(new
            {
                status = 200,
                Matches = Matches,
            }));
        }