fixing some of the bugs with the routes