Module: nagvis
Branch: master
Commit: 0628b57f9cb291b2fc77da806b186bcbf744b2ab
URL:    
http://nagvis.git.sourceforge.net/git/gitweb.cgi?p=nagvis/nagvis;a=commit;h=0628b57f9cb291b2fc77da806b186bcbf744b2ab

Author: Lars Michelsen <[email protected]>
Date:   Tue Oct 20 21:00:32 2009 +0200

Fixed autoload and error handler

---

 share/server/core/functions/ajaxErrorHandler.php |    3 +--
 share/server/core/functions/autoload.php         |    6 +++++-
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/share/server/core/functions/ajaxErrorHandler.php 
b/share/server/core/functions/ajaxErrorHandler.php
index 7a2720c..b7e95ec 100644
--- a/share/server/core/functions/ajaxErrorHandler.php
+++ b/share/server/core/functions/ajaxErrorHandler.php
@@ -38,8 +38,7 @@ function ajaxError($errno, $errstr, $file, $line) {
 }
 
 // Enable custom error handling
-ini_set('display_errors', 0);
-set_error_handler("ajaxError");
+set_error_handler('ajaxError');
 if(function_exists('set_exception_handler')) {
        set_exception_handler('ajaxError');
 }
diff --git a/share/server/core/functions/autoload.php 
b/share/server/core/functions/autoload.php
index 32ec74f..b9d0be4 100644
--- a/share/server/core/functions/autoload.php
+++ b/share/server/core/functions/autoload.php
@@ -30,7 +30,11 @@
  * @author     Lars Michelsen <[email protected]>
  */
 function NagVisAutoload($sClass) {
-       if(substr($sClass, 0, 8) === 'Frontend' || substr($sClass, 0, 4) === 
'Core' || substr($sClass, 0, 6) === 'NagVis' || substr($sClass, 0, 6) === 
'Global') {
+       if(substr($sClass, 0, 8) === 'Frontend' 
+          || substr($sClass, 0, 4) === 'Core' 
+          || substr($sClass, 0, 6) === 'NagVis'
+          || substr($sClass, 0, 6) === 'Nagios' 
+          || substr($sClass, 0, 6) === 'Global') {
                require($sClass.'.php');
                return true;
        } else {


------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Nagvis-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nagvis-checkins

Reply via email to