mirror of
https://github.com/umami-software/umami.git
synced 2026-02-04 12:47:13 +01:00
Refactored permissions check. Updated redis lib.
This commit is contained in:
parent
1a7369e1f6
commit
a4e80ca3e5
5 changed files with 58 additions and 15 deletions
|
|
@ -1,5 +1,5 @@
|
|||
import { User, Website } from '@prisma/client';
|
||||
import redis, { DELETED } from 'lib/redis';
|
||||
import redis from 'lib/redis';
|
||||
import { getSession, getUser, getWebsite } from '../queries';
|
||||
|
||||
async function fetchObject(key, query) {
|
||||
|
|
@ -23,7 +23,7 @@ async function storeObject(key, data) {
|
|||
}
|
||||
|
||||
async function deleteObject(key) {
|
||||
return redis.set(key, DELETED);
|
||||
return redis.set(key, redis.DELETED);
|
||||
}
|
||||
|
||||
async function fetchWebsite(id): Promise<Website> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue