Files
automatisch/packages/backend/src/controllers/api/v1/flows/delete-flow.js
2024-09-14 21:54:10 +03:00

11 lines
235 B
JavaScript

export default async (request, response) => {
const flow = await request.currentUser.authorizedFlows
.clone()
.findById(request.params.flowId)
.throwIfNotFound();
await flow.delete();
response.status(204).end();
};