feat: Added intial dashboard and minecraft connection
Some checks failed
Build and Deploy / Deploy Web (push) Failing after 1s
Build and Deploy / Deploy Discord Bot (push) Failing after 1s

This commit is contained in:
2023-06-13 16:29:47 +02:00
parent c8a4507253
commit c433e25fba
7 changed files with 152 additions and 10 deletions

View File

@@ -15,10 +15,10 @@ export default defineEventHandler(async (event) => {
if (!whitelistDoc) {
throw createError({ statusCode: 500, statusMessage: 'Whitelist document was not found' })
}
} catch (e) {
} catch (e: any) {
console.error('Failed to get whitelist document', e)
throw createError('Failed to get whitelist document')
throw createError({ statusCode: 400, statusMessage: e.statusMessage ? e.statusMessage : 'Failed to get whitelist document' })
}
const minecraftProfile: any = await $fetch(`https://sessionserver.mojang.com/session/minecraft/profile/${whitelistDoc.uuid}`)