Ticket #14046: patch.diff

File patch.diff, 1.7 KB (added by mariarchi, 13 years ago)
  • django/template/loader_tags.py

     
    149149            template_name = self.template_name.resolve(context)                                                 
    150150            t = get_template(template_name)                                                                     
    151151            return t.render(context)                                                                           
    152         except TemplateSyntaxError, e:                                                                         
     152        except:                                                                                                
    153153            if settings.TEMPLATE_DEBUG:                                                                         
    154154                raise                                                                                           
    155             return ''                                                                                           
    156         except:                                                                                                 
    157             return '' # Fail silently for invalid included templates.                                           
     155            return '' # Fail silently for invalid included templates if settings,TEMPLATE_DEBUG is False       
    158156                                                                                                               
    159157def do_block(parser, token):                                                                                   
    160158    """         
Back to Top