1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00

Remove obsolete route (#5092)

This route is no longer needed
This commit is contained in:
Tim Neutkens 2018-09-04 15:59:48 +02:00 committed by GitHub
parent 9abbea8571
commit b39b44ac23
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -184,11 +184,6 @@ export default class Server {
// (but it should support as many as params, seperated by '/')
// Othewise this will lead to a pretty simple DOS attack.
// See more: https://github.com/zeit/next.js/issues/2617
routes['/_next/:path*'] = async (req, res, params) => {
const p = join(__dirname, '..', 'client', ...(params.path || []))
await this.serveStatic(req, res, p)
}
routes['/:path*'] = async (req, res, params, parsedUrl) => {
const { pathname, query } = parsedUrl
await this.render(req, res, pathname, query, parsedUrl)