fix bugs in plan from recipe