Fix failure when there is no plan.