Ticket #6423: views_debug_string_exceptions.diff

File views_debug_string_exceptions.diff, 654 bytes (added by Thomas Güttler, 17 years ago)

Same diff, but with PEP8 coding style

  • django/views/debug.py

     
    7373    template_info = None
    7474    template_does_not_exist = False
    7575    loader_debug_info = None
     76
     77    # Handle deprecated string exceptions
     78    if isinstance(exc_type, basestring):
     79        exc_value = Exception('Deprecated String Exception: %r' % exc_type)
     80        exc_type = type(exc_value)
     81
    7682    if issubclass(exc_type, TemplateDoesNotExist):
    7783        from django.template.loader import template_source_loaders
    7884        template_does_not_exist = True
Back to Top