mirror of
https://git.friendi.ca/friendica/friendica-addons.git
synced 2024-11-25 06:43:40 +00:00
[twitter] Add support for the new support_follow hook
This commit is contained in:
parent
31dd9f8e22
commit
7a1d3302d0
1 changed files with 8 additions and 0 deletions
|
@ -104,6 +104,7 @@ function twitter_install()
|
||||||
Hook::register('notifier_normal' , __FILE__, 'twitter_post_hook');
|
Hook::register('notifier_normal' , __FILE__, 'twitter_post_hook');
|
||||||
Hook::register('jot_networks' , __FILE__, 'twitter_jot_nets');
|
Hook::register('jot_networks' , __FILE__, 'twitter_jot_nets');
|
||||||
Hook::register('cron' , __FILE__, 'twitter_cron');
|
Hook::register('cron' , __FILE__, 'twitter_cron');
|
||||||
|
Hook::register('support_follow' , __FILE__, 'twitter_support_follow');
|
||||||
Hook::register('follow' , __FILE__, 'twitter_follow');
|
Hook::register('follow' , __FILE__, 'twitter_follow');
|
||||||
Hook::register('unfollow' , __FILE__, 'twitter_unfollow');
|
Hook::register('unfollow' , __FILE__, 'twitter_unfollow');
|
||||||
Hook::register('expire' , __FILE__, 'twitter_expire');
|
Hook::register('expire' , __FILE__, 'twitter_expire');
|
||||||
|
@ -135,6 +136,13 @@ function twitter_check_item_notification(App $a, array &$notification_data)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function twitter_support_follow(App $a, array &$data)
|
||||||
|
{
|
||||||
|
if ($data['protocol'] == Protocol::TWITTER) {
|
||||||
|
$data['result'] = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function twitter_follow(App $a, array &$contact)
|
function twitter_follow(App $a, array &$contact)
|
||||||
{
|
{
|
||||||
Logger::info('Check if contact is twitter contact', ['url' => $contact["url"]]);
|
Logger::info('Check if contact is twitter contact', ['url' => $contact["url"]]);
|
||||||
|
|
Loading…
Reference in a new issue