From 46a44bf7f6a2b4b7242fe0ddc2733c5a77bd8406 Mon Sep 17 00:00:00 2001 From: Phill Pover Date: Mon, 7 Apr 2025 04:36:33 +0100 Subject: [PATCH] Adding catches# --- frontend/src/app/actions.tsx | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/frontend/src/app/actions.tsx b/frontend/src/app/actions.tsx index 739660b..49bebe1 100644 --- a/frontend/src/app/actions.tsx +++ b/frontend/src/app/actions.tsx @@ -7,7 +7,7 @@ export async function getAlbums() { }).then(response => { return response.json(); }).catch(error => { - console.error(error); + console.log(error); }); } @@ -18,7 +18,7 @@ export async function getAlbum(id: number) { }).then(response => { return response.json(); }).catch(error => { - console.error(error); + console.log(error); }); } @@ -37,7 +37,7 @@ export async function createAlbum(formData: FormData) { }).then(response => { return response.json(); }).catch(error => { - console.error(error); + console.log(error); }); } @@ -60,7 +60,7 @@ export async function updateAlbum(formData: FormData) { console.log(response.json()); return response.json(); }).catch(error => { - console.error(error); + console.log(error); }); } @@ -74,7 +74,7 @@ export async function deleteAlbum(id: number) { }).then(response => { return response.json(); }).catch(error => { - console.error(error); + console.log(error); }); } @@ -85,7 +85,7 @@ export async function getSongs() { }).then(response => { return response.json(); }).catch(error => { - console.error(error); + console.log(error); }); } @@ -96,7 +96,7 @@ export async function getSong(id: number) { }).then(response => { return response.json(); }).catch(error => { - console.error(error); + console.log(error); }); } @@ -117,7 +117,7 @@ export async function createSong(formData: FormData) { }).then(response => { return response.json(); }).catch(error => { - console.error(error); + console.log(error); }); } @@ -140,7 +140,7 @@ export async function updateSong(formData: FormData) { }).then(response => { return response.json(); }).catch(error => { - console.error(error); + console.log(error); }); } @@ -151,6 +151,6 @@ export async function deleteSong(id: number) { }).then(response => { return response.json(); }).catch(error => { - console.error(error); + console.log(error); }); }