Create and list apps

This commit is contained in:
Kiran 2022-02-05 22:35:37 +05:30
parent ca5410af6d
commit 8680155ccb

View File

@ -18,12 +18,14 @@ export default async function handler(
return res.status(405).end(`Method ${req.method} Not Allowed`); return res.status(405).end(`Method ${req.method} Not Allowed`);
} }
// Get all apps
async function getAllApps() { async function getAllApps() {
const appList = await apps.getAll(); const appList = await apps.getAll();
return res.json(appList); return res.json(appList);
} }
// Create a new app
async function createApp() { async function createApp() {
const { const {
name, name,