forked from friendica/friendica-addons
Use new hook registration calls
This commit is contained in:
parent
d5d909d460
commit
6d708e5246
|
@ -7,6 +7,7 @@
|
|||
*/
|
||||
|
||||
use Friendica\Core\Addon;
|
||||
use Friendica\Core\Hook;
|
||||
use Friendica\Core\Logger;
|
||||
use Friendica\Core\Renderer;
|
||||
use Friendica\Core\System;
|
||||
|
@ -26,11 +27,11 @@ use Friendica\DI;
|
|||
* @brief Installation hook for retriever plugin
|
||||
*/
|
||||
function retriever_install() {
|
||||
Addon::registerHook('addon_settings', 'addon/retriever/retriever.php', 'retriever_addon_settings');
|
||||
Addon::registerHook('addon_settings_post', 'addon/retriever/retriever.php', 'retriever_addon_settings_post');
|
||||
Addon::registerHook('post_remote', 'addon/retriever/retriever.php', 'retriever_post_remote_hook');
|
||||
Addon::registerHook('contact_photo_menu', 'addon/retriever/retriever.php', 'retriever_contact_photo_menu');
|
||||
Addon::registerHook('cron', 'addon/retriever/retriever.php', 'retriever_cron');
|
||||
Hook::register('addon_settings', 'addon/retriever/retriever.php', 'retriever_addon_settings');
|
||||
Hook::register('addon_settings_post', 'addon/retriever/retriever.php', 'retriever_addon_settings_post');
|
||||
Hook::register('post_remote', 'addon/retriever/retriever.php', 'retriever_post_remote_hook');
|
||||
Hook::register('contact_photo_menu', 'addon/retriever/retriever.php', 'retriever_contact_photo_menu');
|
||||
Hook::register('cron', 'addon/retriever/retriever.php', 'retriever_cron');
|
||||
|
||||
if (DI::config()->get('retriever', 'dbversion') == '0.14') {
|
||||
if (!DBA::e("ALTER TABLE `retriever_rule` CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci") ||
|
||||
|
@ -62,13 +63,13 @@ function retriever_install() {
|
|||
* @brief Uninstallation hook for retriever plugin
|
||||
*/
|
||||
function retriever_uninstall() {
|
||||
Addon::unregisterHook('addon_settings', 'addon/retriever/retriever.php', 'retriever_addon_settings');
|
||||
Addon::unregisterHook('addon_settings_post', 'addon/retriever/retriever.php', 'retriever_addon_settings_post');
|
||||
Addon::unregisterHook('post_remote', 'addon/retriever/retriever.php', 'retriever_post_remote_hook');
|
||||
Addon::unregisterHook('addon_settings', 'addon/retriever/retriever.php', 'retriever_addon_settings');
|
||||
Addon::unregisterHook('addon_settings_post', 'addon/retriever/retriever.php', 'retriever_addon_settings_post');
|
||||
Addon::unregisterHook('contact_photo_menu', 'addon/retriever/retriever.php', 'retriever_contact_photo_menu');
|
||||
Addon::unregisterHook('cron', 'addon/retriever/retriever.php', 'retriever_cron');
|
||||
Hook::unregister('addon_settings', 'addon/retriever/retriever.php', 'retriever_addon_settings');
|
||||
Hook::unregister('addon_settings_post', 'addon/retriever/retriever.php', 'retriever_addon_settings_post');
|
||||
Hook::unregister('post_remote', 'addon/retriever/retriever.php', 'retriever_post_remote_hook');
|
||||
Hook::unregister('addon_settings', 'addon/retriever/retriever.php', 'retriever_addon_settings');
|
||||
Hook::unregister('addon_settings_post', 'addon/retriever/retriever.php', 'retriever_addon_settings_post');
|
||||
Hook::unregister('contact_photo_menu', 'addon/retriever/retriever.php', 'retriever_contact_photo_menu');
|
||||
Hook::unregister('cron', 'addon/retriever/retriever.php', 'retriever_cron');
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue