mirror of
https://github.com/pheralb/svgl.git
synced 2025-12-29 08:01:36 +08:00
⚙️ Trying to fix prod deployment
This commit is contained in:
+3
-1
@@ -2,8 +2,10 @@ import { Redis } from '@upstash/redis';
|
|||||||
import { Ratelimit } from '@upstash/ratelimit';
|
import { Ratelimit } from '@upstash/ratelimit';
|
||||||
import { UPSTASH_REDIS_TOKEN, UPSTASH_REDIS_URL, SVGL_API_REQUESTS } from '$env/static/private';
|
import { UPSTASH_REDIS_TOKEN, UPSTASH_REDIS_URL, SVGL_API_REQUESTS } from '$env/static/private';
|
||||||
|
|
||||||
|
const cleanUrl = UPSTASH_REDIS_URL.replace(/^['"]|['"]$/g, '').trim();
|
||||||
|
|
||||||
const redis = new Redis({
|
const redis = new Redis({
|
||||||
url: UPSTASH_REDIS_URL,
|
url: cleanUrl,
|
||||||
token: UPSTASH_REDIS_TOKEN
|
token: UPSTASH_REDIS_TOKEN
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user