Update page.tsx

This commit is contained in:
Damien Ostler 2024-06-03 02:39:11 -04:00
parent a6d050c35f
commit 96aeca6242

View File

@ -107,7 +107,7 @@ function PageComponent() {
const deleteGallery = async () => {
const urlParams = new URLSearchParams(window.location.search);
const id = urlParams.get('id');
const response = await fetch(`/api/gallery/admin/${id}`, {
const response = await fetch(`/api/gallery/admin/${gallery.name}`, {
method: 'DELETE',
headers: {
'Content-Type': 'application/json'