added delete route, fixed bugs in patch route.