CRM-19505 - CRM_Core_Error::handle() - Fix detection of mysql driver
authorTim Otten <totten@civicrm.org>
Fri, 14 Oct 2016 14:17:20 +0000 (15:17 +0100)
committerTim Otten <totten@civicrm.org>
Fri, 14 Oct 2016 14:22:49 +0000 (15:22 +0100)
commit0828e4ad344b4435796eb5e821b4233e3121e611
tree0136f217cabf62de24adcd3d01749674e4850b08
parent094bb7248b7e0d6f687a900d32877ffbf3f28276
CRM-19505 - CRM_Core_Error::handle() - Fix detection of mysql driver

The check `preg_match('/^mysql:/', $_DB_DATAOBJECT['CONFIG']['database'])`
assumes that the admin is manually changing `CIVICRM_DSN` to indicate
preferred driver. Since we determine the driver automatically in 4.7.12+,
this check doesn't work.

This new check determines what driver is actually in use.
CRM/Core/Error.php