import type { Request, Response } from 'express' import addContractFeeCategory, { type AddContractCategoryForm } from '../../database/addContractFeeCategory.js' import getContractFees from '../../database/getContractFees.js' export default async function handler( request: Request, response: Response ): Promise { await addContractFeeCategory( request.body, request.session.user as User ) const contractFees = await getContractFees( request.body.contractId as string ) response.json({ success: true, contractFees }) }