Show
Ignore:
Timestamp:
03/09/2008 03:09:43 PM (10 months ago)
Author:
Shadowhand
Message:

Changes to Kohana exception/error handling:

  • Added KOHANA_ERROR_CSS to index.php
  • Updated error pages to use new KOHANA_ERROR_CSS constant
  • Reflected changes in Kohana and i18n/core.php
  • Kohana::exeception_handler will no longer include the backtrace when IN_PRODUCTION is enabled, for a small security benefit
  • Changed index.php directory checks to only execute when IN_PRODUCTION is enabled, for a small performance benefit
  • Small cleanups in index.php comments
Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/system/core/Kohana.php

    r2229 r2249  
    534534                if (Config::item('core.display_errors')) 
    535535                { 
    536                         if ($line != FALSE) 
     536                        if ( ! IN_PRODUCTION AND $line != FALSE) 
    537537                        { 
    538538                                // Remove the first entry of debug_backtrace(), it is the exception_handler call 
     
    10881088                        if (isset($entry['file'])) 
    10891089                        { 
    1090                                 // Add file (without docroot) 
    1091                                 $temp .= '<strong>'.preg_replace('!^'.preg_quote(DOCROOT).'!', '', $entry['file']); 
    1092                                 // Add line 
    1093                                 $temp .= ' ['.$entry['line'].']:</strong>'; 
     1090                                $temp .= Kohana::lang('core.error_file_line', preg_replace('!^'.preg_quote(DOCROOT).'!', '', $entry['file']), $entry['line']); 
    10941091                        } 
    10951092