feat: trying to add hashes to scripts
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
import { Handlers } from "$fresh/server.ts";
|
||||
import { documentTable } from "@lib/db/schema.ts";
|
||||
import { db } from "@lib/db/sqlite.ts";
|
||||
import { json } from "@lib/helpers.ts";
|
||||
import { caches } from "@lib/cache.ts";
|
||||
import { define } from "../../utils.ts";
|
||||
|
||||
export const handler: Handlers = {
|
||||
export const handler = define.handlers({
|
||||
async DELETE() {
|
||||
for (const cache of caches.values()) {
|
||||
cache.clear();
|
||||
@@ -12,4 +12,4 @@ export const handler: Handlers = {
|
||||
await db.delete(documentTable).run();
|
||||
return json({ status: "ok" });
|
||||
},
|
||||
};
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user