Fix the planner part accordinig to Paul's review