Skip to content

Commit

Permalink
chore(pyroerror): improve error messages
Browse files Browse the repository at this point in the history
Signed-off-by: Evan Song <theevansong@gmail.com>
  • Loading branch information
ferothefox committed Oct 16, 2024
1 parent 8c2294a commit b0cddd8
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
11 changes: 10 additions & 1 deletion apps/frontend/src/components/ui/servers/PyroError.vue
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,11 @@
>
{{ message }}
</h2>
<p class="m-0 max-w-md text-center leading-relaxed text-secondary">
<p v-if="serverId" class="m-0 max-w-md text-center leading-relaxed text-secondary">
If this issue persists, contact Modrinth support and provide the following server ID:
<UiCopyCode :text="serverId" />
</p>
<p v-else class="m-0 max-w-md text-center leading-relaxed text-secondary">
If this issue persists, contact Modrinth support.
</p>
<div class="flex flex-row gap-4">
Expand Down Expand Up @@ -56,6 +60,11 @@ defineProps({
type: String,
required: true,
},
serverId: {
type: String,
default: "",
required: false,
},
});
</script>

Expand Down
7 changes: 6 additions & 1 deletion apps/frontend/src/pages/servers/manage/[id].vue
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
<template>
<div class="contents">
<UiServersPyroError v-if="error" :title="errorTitle" :message="errorMessage" />
<UiServersPyroError
v-if="error"
:title="errorTitle"
:message="errorMessage"
:server-id="serverData?.server_id"
/>
<div
v-if="serverData && serverData.status !== 'installing'"
data-pyro-server-manager-root
Expand Down

0 comments on commit b0cddd8

Please sign in to comment.