mirror of
https://github.com/hotomoe/hotomoe
synced 2024-12-01 08:18:14 +09:00
ハイフンに統一
This commit is contained in:
parent
664acb2d0e
commit
f4ae939124
@ -51,6 +51,10 @@ for (const endpoint of endpoints) {
|
||||
if (endpoint.meta.requireFile) {
|
||||
router.post(`/${endpoint.name}`, upload.single('file'), handler.bind(null, endpoint));
|
||||
} else {
|
||||
if (endpoint.name.includes('-')) {
|
||||
// 後方互換性のため
|
||||
router.post(`/${endpoint.name.replace(/\-/g, '_')}`, handler.bind(null, endpoint));
|
||||
}
|
||||
router.post(`/${endpoint.name}`, handler.bind(null, endpoint));
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user