summaryrefslogtreecommitdiff
path: root/docs/tutorials/wiki
diff options
context:
space:
mode:
Diffstat (limited to 'docs/tutorials/wiki')
-rw-r--r--docs/tutorials/wiki/src/views/tutorial/views/notfound.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/docs/tutorials/wiki/src/views/tutorial/views/notfound.py b/docs/tutorials/wiki/src/views/tutorial/views/notfound.py
index 728791d0a..214ec810e 100644
--- a/docs/tutorials/wiki/src/views/tutorial/views/notfound.py
+++ b/docs/tutorials/wiki/src/views/tutorial/views/notfound.py
@@ -1,7 +1,12 @@
from pyramid.view import notfound_view_config
+from ..models import Page
+
@notfound_view_config(renderer='../templates/404.pt')
def notfound_view(request):
request.response.status = 404
- return {}
+ pagename = request.subpath
+ page = Page(pagename)
+ page.__name__ = pagename
+ return dict(page=page)