public async Task <IActionResult> Delete(Guid id) { var result = await providerRepository.FindByKey(id); if (result == null) { return(NotFound()); } await providerRepository.Delete(result); return(Ok()); }