Skip to content
Snippets Groups Projects
Commit 91e16274 authored by totten's avatar totten
Browse files

(#3496) Missing extension leads to bootstrap error for "hook_civicrm_entityTypes"

parent 548d8fc9
No related branches found
No related tags found
No related merge requests found
......@@ -712,9 +712,12 @@ class CRM_Extension_Manager {
* @return CRM_Extension_Info|NULL
*/
public function createInfoFromDB($key) {
$dao = new CRM_Core_DAO_Extension();
$dao->full_name = $key;
if ($dao->find(TRUE)) {
// System hasn't booted - and extension is missing. Need low-tech/no-hook SELECT to learn more about what's missing.
$select = CRM_Utils_SQL_Select::from('civicrm_extension')
->where('full_name = @key', ['key' => $key])
->select('full_name, type, name, label, file');
$dao = $select->execute();
if ($dao->fetch()) {
$info = new CRM_Extension_Info($dao->full_name, $dao->type, $dao->name, $dao->label, $dao->file);
return $info;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment