mirror of
https://github.com/friendica/friendica
synced 2025-04-26 17:10:10 +00:00
Removed and replaced deprecated functionalities
This commit is contained in:
parent
cfac13790b
commit
eb1b2256a0
12 changed files with 29 additions and 230 deletions
|
@ -320,51 +320,4 @@ class Addon
|
|||
|
||||
return $visible_addons;
|
||||
}
|
||||
|
||||
/**
|
||||
* Shim of Hook::register left for backward compatibility purpose.
|
||||
*
|
||||
* @see Hook::register
|
||||
* @deprecated since version 2018.12
|
||||
* @param string $hook the name of the hook
|
||||
* @param string $file the name of the file that hooks into
|
||||
* @param string $function the name of the function that the hook will call
|
||||
* @param int $priority A priority (defaults to 0)
|
||||
* @return mixed|bool
|
||||
* @throws \Friendica\Network\HTTPException\InternalServerErrorException
|
||||
*/
|
||||
public static function registerHook($hook, $file, $function, $priority = 0)
|
||||
{
|
||||
return Hook::register($hook, $file, $function, $priority);
|
||||
}
|
||||
|
||||
/**
|
||||
* Shim of Hook::unregister left for backward compatibility purpose.
|
||||
*
|
||||
* @see Hook::unregister
|
||||
* @deprecated since version 2018.12
|
||||
* @param string $hook the name of the hook
|
||||
* @param string $file the name of the file that hooks into
|
||||
* @param string $function the name of the function that the hook called
|
||||
* @return boolean
|
||||
* @throws \Friendica\Network\HTTPException\InternalServerErrorException
|
||||
*/
|
||||
public static function unregisterHook($hook, $file, $function)
|
||||
{
|
||||
return Hook::unregister($hook, $file, $function);
|
||||
}
|
||||
|
||||
/**
|
||||
* Shim of Hook::callAll left for backward-compatibility purpose.
|
||||
*
|
||||
* @see Hook::callAll
|
||||
* @deprecated since version 2018.12
|
||||
* @param string $name of the hook to call
|
||||
* @param string|array &$data to transmit to the callback handler
|
||||
* @throws \Friendica\Network\HTTPException\InternalServerErrorException
|
||||
*/
|
||||
public static function callHooks($name, &$data = null)
|
||||
{
|
||||
Hook::callAll($name, $data);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue