includes/common_cli.php
changeset 1378 e58294b867c1
parent 1365 a52cac1b190d
--- a/includes/common_cli.php	Wed Aug 21 22:34:54 2013 -0400
+++ b/includes/common_cli.php	Wed Aug 21 22:50:34 2013 -0400
@@ -36,7 +36,9 @@
 if ( !isset($dbdriver) )
 	$dbdriver = 'mysql';
 
-$db = new $dbdriver();
+$dbdriver_cls = have_pdo($dbdriver) ? "{$dbdriver}_pdo" : $dbdriver;
+
+$db = new $dbdriver_cls();
 $db->connect();
 
 profiler_log('Database connected');