From d3ccd00d5e2a251633e7a35ab3a80c8f97bcc9b1 Mon Sep 17 00:00:00 2001 From: ThatOneCalculator Date: Sun, 2 Jul 2023 00:20:14 -0700 Subject: [PATCH] me when codeberg --- packages/client/src/pages/about-calckey.vue | 7 ++++++- packages/client/src/pages/user/home.vue | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/packages/client/src/pages/about-calckey.vue b/packages/client/src/pages/about-calckey.vue index a8cee78d55..0a22dca4da 100644 --- a/packages/client/src/pages/about-calckey.vue +++ b/packages/client/src/pages/about-calckey.vue @@ -170,7 +170,12 @@ import { defaultStore } from "@/store"; import * as os from "@/os"; import { definePageMetadata } from "@/scripts/page-metadata"; -const patrons = await os.api("patrons", { forceUpdate: true }); +let patrons = []; +try { + patrons = await os.api("patrons", { forceUpdate: true }); +} catch { + console.error("Codeberg's down.") +} let easterEggReady = false; let easterEggEmojis = $ref([]); diff --git a/packages/client/src/pages/user/home.vue b/packages/client/src/pages/user/home.vue index 12da28807e..317656b662 100644 --- a/packages/client/src/pages/user/home.vue +++ b/packages/client/src/pages/user/home.vue @@ -451,7 +451,12 @@ const timeForThem = $computed(() => { return ""; }); -const patrons = await os.api("patrons"); +let patrons = []; +try { + patrons = await os.api("patrons"); +} catch { + console.error("Codeberg's down.") +} function parallaxLoop() { parallaxAnimationId = window.requestAnimationFrame(parallaxLoop);