diff --git a/common/app/NotFound/Not-Found.jsx b/common/app/NotFound/Not-Found.jsx
index 13c796137d6..73f101166ca 100644
--- a/common/app/NotFound/Not-Found.jsx
+++ b/common/app/NotFound/Not-Found.jsx
@@ -1,15 +1,22 @@
import React from 'react';
-
// import PropTypes from 'prop-types';
+import { Alert } from 'react-bootstrap';
const propTypes = {};
export default function NotFound() {
return (
-
404 Not Found
+
+ Oh snap! Page not found!
+
+ Head back to
+
+
+ your current challenge
+
+
);
}
NotFound.displayName = 'NotFound';
NotFound.propTypes = propTypes;
-
diff --git a/common/app/routes/Challenges/Show.jsx b/common/app/routes/Challenges/Show.jsx
index a4741a9dfbc..f8e60cc807b 100644
--- a/common/app/routes/Challenges/Show.jsx
+++ b/common/app/routes/Challenges/Show.jsx
@@ -11,6 +11,7 @@ import Project from './views/project';
import BackEnd from './views/backend';
import Quiz from './views/quiz';
import Modern from './views/Modern';
+import NotFound from '../../NotFound';
import {
fetchChallenge,
@@ -27,7 +28,8 @@ const views = {
project: Project,
quiz: Quiz,
simple: Project,
- step: Step
+ step: Step,
+ invalid: NotFound
};
const mapDispatchToProps = {
diff --git a/common/app/routes/Challenges/redux/index.js b/common/app/routes/Challenges/redux/index.js
index d8aff4e4640..1b681b66734 100644
--- a/common/app/routes/Challenges/redux/index.js
+++ b/common/app/routes/Challenges/redux/index.js
@@ -218,7 +218,10 @@ export const challengeMetaSelector = createSelector(
(...args) => challengeSelector(...args),
challenge => {
if (!challenge.id) {
- return {};
+ const viewType = 'invalid';
+ return {
+ viewType
+ };
}
const challengeType = challenge && challenge.challengeType;
const type = challenge && challenge.type;
diff --git a/common/app/utils/challengeTypes.js b/common/app/utils/challengeTypes.js
index e271239bb02..9dbb1a54d6b 100644
--- a/common/app/utils/challengeTypes.js
+++ b/common/app/utils/challengeTypes.js
@@ -10,3 +10,4 @@ export const bonfire = 5;
export const video = 6;
export const step = 7;
export const quiz = 8;
+export const invalid = 9;