added end_plans needs work