FIX executeHooks $object default value (#29647)

Change $object parameter default value from '' to null to fix issue when using type declarations in custom hooks.

Mirrored change from commit 0453b3e.
This commit is contained in:
Paul Schulte
2024-05-11 14:48:52 -04:00
committed by GitHub
parent ba4f7323fe
commit 1406715ce5

View File

@@ -153,7 +153,7 @@ class HookManager
* All types can also return some values into an array ->results that will be finaly merged into this->resArray for caller.
* $this->error or this->errors are also defined by class called by this function if error.
*/
public function executeHooks($method, $parameters = array(), &$object = '', &$action = '')
public function executeHooks($method, $parameters = array(), &$object = null, &$action = '')
{
if (!is_array($this->hooks) || empty($this->hooks)) {
return 0; // No hook available, do nothing.