1
0
Fork 0
mirror of https://github.com/terribleplan/next.js.git synced 2024-01-19 02:48:18 +00:00
next.js/test
Joe Haddad f43e1a95f1
Set default Error status code to 404 (#6276)
* Set default `Error` status code to 404

This is an appropriate default behavior because:

1. When the server encounters an error, the `err` property is set.
2. When the client-side application crashes, the `err` property is set.

This means the "only" way to render the `/_error` page without an error
is when a page is not found (special condition).

Fixes #6243
Closes #5437

* Add new integration test for client side 404

* single quotes

* Remove unused variable

* Standard needs to go away

* Whoops

* Check for null status code in res and err

* Only check response for valid statusCode
2019-02-12 21:32:25 -05:00
..
integration Set default Error status code to 404 (#6276) 2019-02-12 21:32:25 -05:00
isolated Replace pages-plugin with loader (#5994) 2019-01-08 23:10:32 +01:00
lib Serverless Next.js (#5927) 2018-12-28 11:39:12 +01:00
unit Implement circular JSON err.sh link (#6149) 2019-01-27 16:12:17 +01:00
.babelrc Use preset-react's development option + enable modules transform in test env (#5081) 2018-09-03 16:41:52 +02:00
.gitignore Universal Webpack (#3578) 2018-01-30 16:44:44 +01:00
jest-global-setup.js Refactor test setup (#5391) 2018-10-12 15:32:17 +02:00
jest-global-teardown.js Refactor test setup (#5391) 2018-10-12 15:32:17 +02:00