aboutsummaryrefslogtreecommitdiffstats
path: root/src/routes/(app)/send/ecash/+page.server.ts
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2025-07-16 00:20:03 -0700
committerAdam Soltys <[email protected]>2025-07-16 00:20:03 -0700
commite9a3bccbdd065934a4ac48574d144e79cd5b25bb (patch)
treee523f3a6c88c9d6f5d181dcf05950337c6a4d9b0 /src/routes/(app)/send/ecash/+page.server.ts
parent25ac9d65b346dafb3b1c733cce44feb1c3564aa8 (diff)
downloadcoinos-ui-e9a3bccbdd065934a4ac48574d144e79cd5b25bb.tar.gz
coinos-ui-e9a3bccbdd065934a4ac48574d144e79cd5b25bb.zip
disable ecash
Diffstat (limited to 'src/routes/(app)/send/ecash/+page.server.ts')
-rw-r--r--src/routes/(app)/send/ecash/+page.server.ts26
1 files changed, 0 insertions, 26 deletions
diff --git a/src/routes/(app)/send/ecash/+page.server.ts b/src/routes/(app)/send/ecash/+page.server.ts
deleted file mode 100644
index b290fb95..00000000
--- a/src/routes/(app)/send/ecash/+page.server.ts
+++ /dev/null
@@ -1,26 +0,0 @@
-import getRates from "$lib/rates";
-import { auth, fd, post } from "$lib/utils";
-import { error, redirect } from "@sveltejs/kit";
-
-export async function load({ parent }) {
- const rates = await getRates();
- const { user } = await parent();
- return { rate: rates[user.currency] };
-}
-
-export const actions = {
- default: async ({ cookies, request }) => {
- let id;
- const body = await fd(request);
-
- try {
- ({ id } = await post("/mint", body, auth(cookies)));
- } catch (e) {
- const { message } = e as Error;
- console.log("problem creating ecash", e);
- error(400, { message });
- }
-
- redirect(307, `/ecash/${id}`);
- },
-};