public IActionResult RestoreVehicle(int id) { try { var entity = _vehicleLogic.RestoreVehicle(id); if (entity == null) { return(BadRequest("Somthing went wrong while updating model in DB!")); } return(Ok(entity)); } catch (Exception e) { return(StatusCode(500, e)); } }