Show
Ignore:
Timestamp:
10/04/2007 08:10:40 PM (14 months ago)
Author:
Shadowhand
Message:

A few small changes:

  • Cleaned up debug logging
  • Changed Kohana::display() to be run in the "system.shutdown" Event
  • Changed Bootstrap to call "system.shutdown" as the last operation
Files:
1 modified

Legend:

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

    r651 r652  
    132132                set_exception_handler(array('Kohana', 'exception_handler')); 
    133133 
    134                 // Set shutdown handler to run the 'system.shutdown' event 
    135                 register_shutdown_function(array('Event', 'run'), 'system.shutdown'); 
    136  
    137134                if (function_exists('date_default_timezone_set')) 
    138135                { 
     
    170167                } 
    171168 
     169                // Enable routing 
     170                Event::add('system.routing', array('Router', 'setup')); 
     171 
     172                // Enabel loading a Kohana instance 
     173                Event::add('system.execute', array('Kohana', 'instance')); 
     174 
    172175                // Enable log writing if the log threshold is enabled 
    173176                if(Config::item('log.threshold') > 0) 
     
    176179                } 
    177180 
    178                 // Enable routing 
    179                 Event::add('system.routing', array('Router', 'setup')); 
    180  
    181                 // Enabel loading a Kohana instance 
    182                 Event::add('system.execute', array('Kohana', 'instance')); 
     181                Event::add('system.shutdown', array('Kohana', 'display')); 
    183182 
    184183                // Setup is complete