Skip to content

Commit

Permalink
Handle notFoundPage 404 content
Browse files Browse the repository at this point in the history
  • Loading branch information
jhildenbiddle committed Nov 16, 2023
1 parent a2539a6 commit cad4a95
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/core/render/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -308,9 +308,9 @@ export function Render(Base) {
_renderMain(text, opt = {}, next) {
const { response } = this.route;

// Note: It is possible for the response to be undefined in envrionments
// Note: It is possible for the response to be undefined in environments
// where XMLHttpRequest has been modified or mocked
if (response && !response.ok) {
if (response && !response.ok && (!text || response.status !== 404)) {
text = `# ${response.status} - ${response.statusText}`;
}

Expand Down

0 comments on commit cad4a95

Please sign in to comment.