await FastifyWorker.fastify.register(fastifyPoolifier, workerData)
- FastifyWorker.fastify.all('/api/echo', async request => {
+ FastifyWorker.fastify.all('/api/echo', async (request) => {
return (
await FastifyWorker.fastify.execute({ body: request.body }, 'echo')
).body
FastifyWorker.fastify.get<{
Params: { number: number }
- }>('/api/factorial/:number', async request => {
+ }>('/api/factorial/:number', async (request) => {
const { number } = request.params
return (
await FastifyWorker.fastify.execute({ body: { number } }, 'factorial')