Exemple #1
0
 public IEnumerable <Message> FindMessages([FromBody] DataToFind data)
 {
     try
     {
         return(_messagesRepository.FindMessages(data.Tokens, data.ProfileId));
     }
     catch (SqlException exception)
     {
         var response = new HttpResponseMessage(HttpStatusCode.NotFound)
         {
             Content = new StringContent(exception.Message)
         };
         throw new HttpResponseException(response);
     }
 }