Added guard before an exception is thrown in PlanExecutionPreview.