mirror of
https://github.com/nuxt/nuxt.git
synced 2025-02-06 21:10:38 +00:00
Ignore if in dev mode
This commit is contained in:
parent
095c8efe56
commit
a7e2a87ee4
@ -9,6 +9,7 @@ exports.render = function (req, res) {
|
|||||||
console.error('> No build files found, please run `nuxt build` before launching `nuxt start`') // eslint-disable-line no-console
|
console.error('> No build files found, please run `nuxt build` before launching `nuxt start`') // eslint-disable-line no-console
|
||||||
process.exit(1)
|
process.exit(1)
|
||||||
}
|
}
|
||||||
|
/* istanbul ignore if */
|
||||||
if (!this.renderer) {
|
if (!this.renderer) {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
this.render(req, res)
|
this.render(req, res)
|
||||||
@ -39,6 +40,7 @@ exports.render = function (req, res) {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
.then(() => {
|
.then(() => {
|
||||||
|
/* istanbul ignore if */
|
||||||
if (this.dev && this._nuxtRegexp.test(req.url) && req.url.includes('.hot-update.json')) {
|
if (this.dev && this._nuxtRegexp.test(req.url) && req.url.includes('.hot-update.json')) {
|
||||||
res.statusCode = 404
|
res.statusCode = 404
|
||||||
return res.end()
|
return res.end()
|
||||||
|
Loading…
Reference in New Issue
Block a user