feat: move perf,logs and user into sqlite

This commit is contained in:
2025-01-05 18:03:59 +01:00
parent 1937ef55bb
commit bf7d88a588
25 changed files with 524 additions and 145 deletions

View File

@@ -1,30 +1,30 @@
import { MiddlewareHandlerContext } from "$fresh/server.ts";
import { FreshContext } from "$fresh/server.ts";
class DomainError extends Error {
status = 500;
render?: (ctx: MiddlewareHandlerContext) => void;
render?: (ctx: FreshContext) => void;
constructor(public statusText = "Internal Server Error") {
super();
}
}
class NotFoundError extends DomainError {
status = 404;
constructor(public statusText = "Not Found") {
override status = 404;
constructor(public override statusText = "Not Found") {
super();
}
}
class BadRequestError extends DomainError {
status = 400;
constructor(public statusText = "Bad Request") {
override status = 400;
constructor(public override statusText = "Bad Request") {
super();
}
}
class AccessDeniedError extends DomainError {
status = 403;
constructor(public statusText = "Access Denied") {
override status = 403;
constructor(public override statusText = "Access Denied") {
super();
}
}