Example #1
0
        public async Task <IActionResult> CreateEntity([FromBody] MatchDTO matchDTO)
        {
            try
            {
                MatchDTO createdMatch = await _matchService.CreateEntity(matchDTO);

                return(Ok(createdMatch));
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message);
                return(BadRequest(e.Message));
            }
        }