diff --git a/src/routes/admin/+page.server.js b/src/routes/admin/+page.server.js deleted file mode 100644 index 793c3af..0000000 --- a/src/routes/admin/+page.server.js +++ /dev/null @@ -1,33 +0,0 @@ -import { error } from '@sveltejs/kit'; -import fs from 'fs'; -import stream from 'stream'; -// import { canvas } from '$lib/stores/store'; -import { getAllPostersFromDB, addPosterToDB } from '$lib/db/utils'; - -/** @type {import('./$types').PageServerLoad} */ -export const load = () => { - const posters = getAllPostersFromDB(); - if (posters !== undefined) { - return { - posters - } - } - throw error(404, "error"); -}; - -/** @type {import('./$types').Actions} */ -export const actions = { - default: async ({ request }) => { - console.log("Estoy aquĆ­"); - const path = crypto.randomUUID(); - const data = await request.formData(); - const image = data.get("image")?.toString(); - const content = data.get("content"); - fs.writeFileSync(`./static/${path}.png`, image, 'base64url'); - // const savetoDB = addPosterToDB(image, content); - return { - success: true - } - } - -} diff --git a/src/routes/admin/+page.svelte b/src/routes/admin/+page.svelte deleted file mode 100644 index de890a5..0000000 --- a/src/routes/admin/+page.svelte +++ /dev/null @@ -1,31 +0,0 @@ - - -

Test

- - -
- - - - -
- - diff --git a/src/routes/admin/auth/login/+page.server.js b/src/routes/admin/auth/login/+page.server.js deleted file mode 100644 index e69de29..0000000 diff --git a/src/routes/admin/auth/login/+page.svelte b/src/routes/admin/auth/login/+page.svelte deleted file mode 100644 index e69de29..0000000