improve(api): update api to fastify v5
This commit is contained in:
@@ -1,14 +1,5 @@
|
||||
import type {
|
||||
FastifyReply,
|
||||
FastifyRequest,
|
||||
HookHandlerDoneFunction,
|
||||
} from 'fastify';
|
||||
import type { FastifyRequest } from 'fastify';
|
||||
|
||||
export function timestampHook(
|
||||
request: FastifyRequest,
|
||||
reply: FastifyReply,
|
||||
done: HookHandlerDoneFunction,
|
||||
) {
|
||||
export async function timestampHook(request: FastifyRequest) {
|
||||
request.timestamp = Date.now();
|
||||
done();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user