https://reisub.nsupdate.info/git
/
friendica-addons.git
/
.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Replace deprecated Addon::*registerHook by Hook::*register
[friendica-addons.git/.git]
/
fortunate
/
fortunate.php
diff --git
a/fortunate/fortunate.php
b/fortunate/fortunate.php
index
b92f608
..
939cbb4
100644
(file)
--- a/
fortunate/fortunate.php
+++ b/
fortunate/fortunate.php
@@
-6,7
+6,7
@@
* Author: Mike Macgirvin <http://macgirvin.com/profile/mike>
* Status: Unsupported
*/
* Author: Mike Macgirvin <http://macgirvin.com/profile/mike>
* Status: Unsupported
*/
-use Friendica\Core\
Addon
;
+use Friendica\Core\
Hook
;
use Friendica\Util\Network;
// IMPORTANT: SET THIS to your fortunate server
use Friendica\Util\Network;
// IMPORTANT: SET THIS to your fortunate server
@@
-15,7
+15,7
@@
define('FORTUNATE_SERVER', 'hostname.com');
function fortunate_install()
{
function fortunate_install()
{
-
Addon::registerHook
('page_end', 'addon/fortunate/fortunate.php', 'fortunate_fetch');
+
Hook::register
('page_end', 'addon/fortunate/fortunate.php', 'fortunate_fetch');
if (FORTUNATE_SERVER == 'hostname.com' && is_site_admin()) {
notice('Fortunate addon requires configuration. See README');
}
if (FORTUNATE_SERVER == 'hostname.com' && is_site_admin()) {
notice('Fortunate addon requires configuration. See README');
}
@@
-23,7
+23,7
@@
function fortunate_install()
function fortunate_uninstall()
{
function fortunate_uninstall()
{
-
Addon::unregisterHook
('page_end', 'addon/fortunate/fortunate.php', 'fortunate_fetch');
+
Hook::unregister
('page_end', 'addon/fortunate/fortunate.php', 'fortunate_fetch');
}
}