[Zope-Checkins] SVN: Zope/branches/2.12/src/Zope2/App/startup.py Allow for subclasses of exceptions in the exception hook
Hanno Schlichting
hannosch at hannosch.eu
Thu Jul 2 08:24:19 EDT 2009
Log message for revision 101389:
Allow for subclasses of exceptions in the exception hook
Changed:
U Zope/branches/2.12/src/Zope2/App/startup.py
-=-
Modified: Zope/branches/2.12/src/Zope2/App/startup.py
===================================================================
--- Zope/branches/2.12/src/Zope2/App/startup.py 2009-07-02 11:24:34 UTC (rev 101388)
+++ Zope/branches/2.12/src/Zope2/App/startup.py 2009-07-02 12:24:19 UTC (rev 101389)
@@ -171,7 +171,8 @@
if t.lower() in ('unauthorized', 'redirect'):
raise
else:
- if t is SystemExit or t is Redirect or t is Unauthorized:
+ if (t is SystemExit or
+ issubclass(t, Redirect) or issubclass(t, Unauthorized)):
raise
if issubclass(t, ConflictError):
More information about the Zope-Checkins
mailing list