]> git.mxchange.org Git - mailer.git/blobdiff - inc/db/lib.php
Fixed a typo, thanks to profi-concept. Function INCLUDE_READABLE() introduced
[mailer.git] / inc / db / lib.php
index 7578d6077012f93178cb010603cf24948f56ea63..e5c8ab3d9fb11d5551328490c63aa4f75f8e3846 100644 (file)
@@ -38,17 +38,17 @@ if (!defined('__SECURITY')) {
 }
 
 // Select MySQL 3 as default database type
-if (_DB_TYPE == "_DB_TYPE") define('_DB_TYPE', "mysql3");
+if (!defined('_DB_TYPE')) define('_DB_TYPE', "mysql3");
 
 // Create include file name
-$INC = sprintf("%sinc/db/lib-%s.php", PATH, _DB_TYPE);
+$INC = sprintf("inc/db/lib-%s.php", constant('_DB_TYPE'));
 
-if ((file_exists($INC)) && (is_readable($INC))) {
+if (INCLUDE_READABLE($INC)) {
        // Include abstraction layer
-       require_once($INC);
+       LOAD_INC_ONCE($INC);
 } else {
        // Bye, bye...
-       die("Cannot load database abstraction layer! R.I.P.");
+       die("Cannot load database abstraction layer ".constant('_DB_TYPE')." -> R.I.P.");
 }
 
 //