public IActionResult DeleteFlight(string id) { if (_flightsManager.DeleteFlightPlan(id)) { return(Ok()); } return(BadRequest(new Error("Could not delete flight."))); }
public ActionResult DeleteFlight(string id) { if (myFlightsManager.DeleteFlightPlan(id)) { return(Ok()); } // if the flight was not found return(NotFound("Flight wasn't found")); }