Changes (/shrug)

* Added middleware timer for performance debugging
* Relationships and avatar database keys
* CDN
* Profiles are SelfAccounts in most cases, rather than Accounts
* Simplified profile content management
* Progression fixes
* Relationships (favorites not yet implemented)
* Relationship backend
* Relationship and avatar routes
This commit is contained in:
2025-03-31 01:48:46 -04:00
parent 639e809a20
commit 638c0fbf1f
19 changed files with 999 additions and 65 deletions

View File

@@ -338,4 +338,12 @@ export function LoginLock(rq: express.Request<NoBody, NoBody, { LoginLock: strin
export type NoBody = Record<string | number | symbol, never>;
export function startTimer(rq: express.Request, rs: express.Response, nxt: express.NextFunction) {
rs.locals.timer = performance.now();
nxt();
}
export function stopTimer(_rq: express.Request, rs: express.Response) {
log.n(`(${rs.locals.reqId.substring(0, 11)}) Middleware took ${(performance.now() - rs.locals.timer).toString().substring(0, 6)} ms`);
}
export * as APIUtils from "./apiutils.ts";