From 68ed6cc798457c684a37ef8cc627f6404d88be1d Mon Sep 17 00:00:00 2001
From: Fuwn <contact@fuwn.me>
Date: Tue, 5 Dec 2023 21:01:28 -0800
Subject: fix(wrapped): fix proxy for dev

---
 src/lib/Tools/Wrapped.svelte | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'src/lib/Tools/Wrapped.svelte')

diff --git a/src/lib/Tools/Wrapped.svelte b/src/lib/Tools/Wrapped.svelte
index 75fd4a76..77e9f52c 100644
--- a/src/lib/Tools/Wrapped.svelte
+++ b/src/lib/Tools/Wrapped.svelte
@@ -13,7 +13,7 @@
 	import manga from '../../stores/manga.js';
 	import Error from '$lib/Error.svelte';
 	import { domToBlob } from 'modern-screenshot';
-	import { browser } from '$app/environment';
+	import { browser, dev } from '$app/environment';
 	import { page } from '$app/stores';
 	import { clearAllParameters } from './tool.js';
 
@@ -301,7 +301,7 @@
 	// 	return string.slice(0, maxLength - 3) + ' …';
 	// };
 
-	const proxy = (url: string) => `/api/proxy?url=${encodeURIComponent(url)}`;
+	const proxy = (url: string) => (dev ? url : `/api/proxy?url=${encodeURIComponent(url)}`);
 </script>
 
 {#if currentUserIdentity.id === -2}
-- 
cgit v1.2.3

