}); $routes->get('/drink/:id', function ($id) { DrinkController::show($id); }); $routes->get('/addDrink', function () { DrinkController::addNew(); }); $routes->post('/addDrink', function () { DrinkController::store(); }); $routes->post('/drink/:id/destroy', function ($id) { DrinkController::destroy($id); }); $routes->get('/drink/:id/edit', function ($id) { DrinkController::edit($id); }); $routes->post('/drink/:id/edit?', function ($id) { DrinkController::update($id); }); $routes->get('/search', function () { DrinkController::showSearchPage(); }); $routes->post('/search', function () { DrinkController::showSearchResults(); }); $routes->post('/favorites/:id/destroy', function ($id) { UserController::removeFav($id); }); $routes->post('/drink/:id/favorite', function ($id) { UserController::addFav($id); });