Ejemplo n.º 1
0
 public Response EditResponseVotes(string command, int responseId)
 {
     try
     {
         var response = _context.Responses.SingleOrDefault(res => res.Id == responseId);
         response = ResponseValidator.ValidateCommand(response, command);
         _context.Responses.Update(response);
         _context.SaveChanges();
         return(response);
     }
     catch (Exception)
     {
         throw;
     }
 }