良い感じに
This commit is contained in:
parent
1e4a86da8e
commit
1744316656
8 changed files with 76 additions and 50 deletions
|
@ -35,7 +35,7 @@ const router = new Router();
|
|||
/**
|
||||
* Register endpoint handlers
|
||||
*/
|
||||
endpoints.forEach(endpoint => endpoint.withFile
|
||||
endpoints.forEach(endpoint => endpoint.meta.withFile
|
||||
? router.post(`/${endpoint.name}`, upload.single('file'), handler.bind(null, endpoint))
|
||||
: router.post(`/${endpoint.name}`, handler.bind(null, endpoint))
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue