public async Task <ActionResponse> DeleteFeature(int featureId) { try { if (featureId == 0) { return(new ActionResponse { Message = "Nothing was deleted on id = 0", Status = ActionStatus.Warning }); } await _securityContext.DeleteFeature(featureId); return(new ActionResponse { Status = ActionStatus.Success }); } catch (SecurityDbException e) { return(new ActionResponse { Status = ActionStatus.Warning, Message = PrettyExceptionHelper.GetMessage(e) }); } catch (Exception e) { Console.WriteLine(e); return(new ActionResponse { Status = ActionStatus.Error, Message = "Something went wrong!" }); } }