123456789101112131415161718192021222324252627282930313233343536373839404142 |
- <?php
- defined('GNUSOCIAL') || die();
- require_once dirname(__DIR__) . '/twitter.php';
- class TwitterQueueHandler extends QueueHandler
- {
- function transport()
- {
- return 'twitter';
- }
- function handle($notice) : bool
- {
- if (!($notice instanceof Notice)) {
- common_log(LOG_ERR, "Got a bogus notice, not broadcasting");
- return true;
- }
- $ok = broadcast_twitter($notice);
- return $ok || common_config('twitter', 'ignore_errors');
- }
- }
|