switched up the routes and implementing REST