From 4b1ecdf9a217ab49188bdb2ffe33055ab411def2 Mon Sep 17 00:00:00 2001 From: GRZ4NA Date: Sun, 3 Oct 2021 16:03:57 +0200 Subject: [PATCH] removed old getEvents utility function --- src/utils/api/getEvents.js | 8 -------- 1 file changed, 8 deletions(-) delete mode 100644 src/utils/api/getEvents.js diff --git a/src/utils/api/getEvents.js b/src/utils/api/getEvents.js deleted file mode 100644 index 823cccc..0000000 --- a/src/utils/api/getEvents.js +++ /dev/null @@ -1,8 +0,0 @@ -import axios from "axios"; -import { BACKEND_URL } from "../../constants"; - -export const getEvents = async () => { - const rq = await axios.get(`${BACKEND_URL}/api/getEvents`); - if (rq.status !== 200) throw new Error(`Request failed with code ${rq.status}: ${rq.statusText}`); - return rq.data; -};