corrected recursive function draw_route