fix(api): just return text instead

This commit is contained in:
taskylizard 2024-07-28 08:33:03 +00:00
parent ee0cff3edc
commit 2eaf4485ff
No known key found for this signature in database
GPG key ID: 1820131ED1A24120

View file

@ -30,8 +30,6 @@ export default defineEventHandler(async () => {
}) })
try { try {
// event.waitUntil(async () => {
// Fetch the list of files in the repository // Fetch the list of files in the repository
const files = await f.get<File[]>(GITHUB_REPO) const files = await f.get<File[]>(GITHUB_REPO)
@ -57,7 +55,6 @@ export default defineEventHandler(async () => {
) )
body += contents.join('\n\n') body += contents.join('\n\n')
// })
} catch (error) { } catch (error) {
return { return {
status: 500, status: 500,
@ -65,8 +62,5 @@ export default defineEventHandler(async () => {
} }
} }
return { return body
status: 200,
body
}
}) })