From ed61e0b732fa79bba182222758086f63337168cf Mon Sep 17 00:00:00 2001 From: Davide Franco Date: Mon, 27 Jun 2011 16:53:54 +0200 Subject: [PATCH] bacula-web: Improved GetDBSize() function - Removed useless fetch mode (as the default mode already defined) - Used TriggerDBEror() function in db query exception --- gui/bacula-web/includes/bweb.inc.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gui/bacula-web/includes/bweb.inc.php b/gui/bacula-web/includes/bweb.inc.php index a7fc2cfd4c..d4867d9581 100644 --- a/gui/bacula-web/includes/bweb.inc.php +++ b/gui/bacula-web/includes/bweb.inc.php @@ -149,10 +149,10 @@ class Bweb extends DB if(! PEAR::isError( $result ) ) { - $db = $result->fetchRow( DB_FETCHMODE_ASSOC ); + $db = $result->fetchRow(); $database_size = $db['dbsize']; }else - die( "Unable to get database size
" . $result->getMessage() ); + $this->TriggerDBError( 'Unable to get database size', $result); return CUtils::Get_Human_Size( $database_size ); } // end function GetDbSize() -- 2.39.5