forked from extern/egroupware
method to test which apps implement a hook
This commit is contained in:
parent
bb17f1ae3d
commit
24604bdb5d
@ -201,6 +201,18 @@ class hooks
|
|||||||
return count($this->locations[$location][$app]);
|
return count($this->locations[$location][$app]);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* check which apps implement a given hook
|
||||||
|
*
|
||||||
|
* @param string $location location-name
|
||||||
|
* @return array of apps implementing given hook
|
||||||
|
*/
|
||||||
|
function hook_implemented($location)
|
||||||
|
{
|
||||||
|
//error_log(__METHOD__.__LINE__.array2string($this->locations[$location]));
|
||||||
|
return isset($this->locations[$location]) ? array_keys($this->locations[$location]) : array();
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Register and/or de-register an application's hooks
|
* Register and/or de-register an application's hooks
|
||||||
*
|
*
|
||||||
|
Loading…
Reference in New Issue
Block a user