Skip to content

Commit

Permalink
chore: remove forward slash
Browse files Browse the repository at this point in the history
  • Loading branch information
svedova committed Oct 13, 2023
1 parent 3193008 commit 25aef86
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/middlewares/express.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,7 @@ export default (opts: Options) => async (req: Request, res: Response) => {
}

if (opts.moduleLoader) {
const handler = await opts.moduleLoader(
`/${path.join(apiDir, route).replace(/^\/+/, "")}`
);
const handler = await opts.moduleLoader(path.join(apiDir, route));

invokeApiHandler(handler, req, res).then((data) => {
if (!data) {
Expand Down

0 comments on commit 25aef86

Please sign in to comment.