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:
@@ -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";
|
||||
|
||||
Reference in New Issue
Block a user