Local modifications to ClusterLabs/Anvil by Alteeve
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

20 lines
436 B

import { NextApiRequest, NextApiResponse } from 'next';
import getAllAnvil from './getAllAnvil';
async function handleAPIGetAllAnvil(
request: NextApiRequest,
response: NextApiResponse,
): Promise<void> {
const { anvilList, error }: GetAllAnvilResponse = await getAllAnvil();
if (error) {
response.status(503);
} else {
response.status(200);
}
response.send(anvilList);
}
export default handleAPIGetAllAnvil;