public async Task <IHttpActionResult> Get() { try { var result = await _repository.GetAllSuppliersAsync(); if (result != null) { var mappedResult = _mapper.Map <IEnumerable <SupplierModel> >(result); return(Ok(mappedResult)); } else { return(Content(HttpStatusCode.NotFound, "No suppliers could be found")); }; } catch { return(InternalServerError()); } }