public HttpResponseMessage GetResultByCompetitionId(int competitionId)
        {
            //Retrieves the result of the competition related with the given id
            var teamCompetitions = _repository.GetResultByCompetitionId(competitionId);

            CustomResponse response;

            //Retrieves competition
            Competition competition = _repository.GetById(competitionId);

            if (teamCompetitions == null || competition == null)
            {
                response = ResponseMessageHelper.CreateResponse(HttpStatusCode.NotFound, true, HttpStatusCode.NotFound, ConstantResponse.COMPETITION_RESULT_NOT_FOUND);
                return(Request.CreateResponse <CustomResponse>(HttpStatusCode.NotFound, response));
            }


            //Mapping to related DTO
            CompetitionResultDTO result = GenericMapper.MapToCompetitionResultDTO(teamCompetitions, competition);

            response = ResponseMessageHelper.CreateResponse(HttpStatusCode.OK, false, result, ConstantResponse.COMPETITION_RESULT_SUCCESS);
            return(Request.CreateResponse <CustomResponse>(HttpStatusCode.OK, response));
        }