File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -30,7 +30,7 @@ export class PackageLikesUtils {
3030 return { data, isStale : false , cachedAt : null }
3131 } ,
3232 )
33- this . cache = getCacheAdatper ( 'generic' )
33+ this . cache = getCacheAdapter ( 'generic' )
3434 }
3535
3636 /**
Original file line number Diff line number Diff line change 11import { Redis } from '@upstash/redis'
22
3- export function getCacheAdatper ( prefix : string ) : CacheAdapter {
3+ export function getCacheAdapter ( prefix : string ) : CacheAdapter {
44 const config = useRuntimeConfig ( )
55
66 if ( ! import . meta. dev && config . upstash ?. redisRestUrl && config . upstash ?. redisRestToken ) {
77 const redis = new Redis ( {
88 url : config . upstash . redisRestUrl ,
99 token : config . upstash . redisRestToken ,
1010 } )
11- return new RedisCacheAdatper ( redis , prefix )
11+ return new RedisCacheAdapter ( redis , prefix )
1212 }
1313 return new LocalCacheAdapter ( )
1414}
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ import type { Redis } from '@upstash/redis'
33/**
44 * Redis cache storage with TTL handled by redis for use in production
55 */
6- export class RedisCacheAdatper implements CacheAdapter {
6+ export class RedisCacheAdapter implements CacheAdapter {
77 private readonly redis : Redis
88 private readonly prefix : string
99
You can’t perform that action at this time.
0 commit comments