aboutsummaryrefslogtreecommitdiffstats
path: root/src/routes/(app)
diff options
context:
space:
mode:
Diffstat (limited to 'src/routes/(app)')
-rw-r--r--src/routes/(app)/send/invoice/[id]/+page.server.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/routes/(app)/send/invoice/[id]/+page.server.ts b/src/routes/(app)/send/invoice/[id]/+page.server.ts
index c65a6c7b..55228025 100644
--- a/src/routes/(app)/send/invoice/[id]/+page.server.ts
+++ b/src/routes/(app)/send/invoice/[id]/+page.server.ts
@@ -1,4 +1,4 @@
-import { auth, fd, get, post } from "$lib/utils";
+import { auth, fd, get, post, types } from "$lib/utils";
import { error, redirect } from "@sveltejs/kit";
export async function load({ cookies, params: { id }, parent }) {
@@ -14,7 +14,7 @@ export async function load({ cookies, params: { id }, parent }) {
redirect(307, `/invoice/${id}/memo`);
if (invoice.aid === aid) error(500, { message: "Cannot send to self" });
- else if (user) redirect(307, `/send/${invoice.type}/${invoice.hash}`);
+ else if (user && invoice.type !== types.lightning) redirect(307, `/send/${invoice.type}/${invoice.hash}`);
if (!user) redirect(307, `/invoice/${id}`);