???
This commit is contained in:
parent
8acad12e09
commit
087f71caa5
1 changed files with 5 additions and 1 deletions
|
@ -1,7 +1,11 @@
|
||||||
import { Redis } from "ioredis";
|
import { Redis } from "ioredis";
|
||||||
import { env } from "env.mjs";
|
import { env } from "env.mjs";
|
||||||
|
|
||||||
export const redis = env.REDIS_URL ? new Redis(env.REDIS_URL) : null;
|
export const redis = env.REDIS_URL
|
||||||
|
? new Redis(env.REDIS_URL, {
|
||||||
|
family: 6,
|
||||||
|
})
|
||||||
|
: null;
|
||||||
|
|
||||||
export const setCache = async <T>(key: string, value: T) => {
|
export const setCache = async <T>(key: string, value: T) => {
|
||||||
console.log(env.REDIS_URL);
|
console.log(env.REDIS_URL);
|
||||||
|
|
Loading…
Add table
Reference in a new issue