Skip to content

Commit 01e3f5b

Browse files
author
Richard Jones
committed
raise not found earlier, where it makes more sense to the user
1 parent 007f410 commit 01e3f5b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

roundup/cgi/client.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Id: client.py,v 1.35 2002-09-16 05:33:58 richard Exp $
1+
# $Id: client.py,v 1.36 2002-09-16 06:39:12 richard Exp $
22

33
__doc__ = """
44
WWW request handler (also used in the stand-alone server).
@@ -297,6 +297,8 @@ def determine_context(self, dre=re.compile(r'([^\d]+)(\d+)')):
297297
if m:
298298
self.classname = m.group(1)
299299
self.nodeid = m.group(2)
300+
if not self.db.getclass(self.classname).hasnode(self.nodeid):
301+
raise NotFound, '%s/%s'%(self.classname, self.nodeid)
300302
# with a designator, we default to item view
301303
self.template = 'item'
302304
else:

0 commit comments

Comments
 (0)