/** * Stop FuzeWorks and run all shutdown functions. * * Afterwards run the Logger shutdown function in order to possibly display the log */ public static function shutdown() { // Fix Apache bug where CWD is changed upon shutdown chdir(self::$cwd); // Fire the Shutdown event $event = Events::fireEvent('coreShutdownEvent'); if ($event->isCancelled() === false) { // If the output should be displayed, send the final render and parse the logger Logger::shutdownError(); Factory::getInstance()->output->_display(); Logger::shutdown(); } }