Skip to content

Commit

Permalink
refactor(js): group routes together
Browse files Browse the repository at this point in the history
Should be in e4c4814 commit.

Relate to #27
  • Loading branch information
php-coder committed Apr 17, 2024
1 parent 87c870a commit d23684d
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion examples/js/express/mysql/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@ const pool = mysql.createPool({
})

routes.register(app, pool)

custom_routes.register(app, pool)

const port = process.env.PORT || 3000
Expand Down
2 changes: 1 addition & 1 deletion src/templates/app.js.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ const pool = mysql.createPool({
routes.register(app, pool)
<% customRouteFilenames.forEach(filename => {
const routerName = removeExtension(filename)
%>
-%>
<%- routerName %>.register(app, pool)
<% }) -%>

Expand Down

0 comments on commit d23684d

Please sign in to comment.