Fix for ticket #3039: TwitterBridge was incorrectly sending repeats of Twitter-bound messages if the repeater has sending of things to Twitter disabled.
A repeat/retweet is roughly equivalent to an active direct post, so should follow the posting rules, rather than always sending over as we do for fave notifications.
This commit is contained in:
parent
857e35c175
commit
2bf8a68908
@ -173,6 +173,7 @@ function broadcast_twitter($notice)
|
|||||||
|
|
||||||
// Don't bother with basic auth, since it's no longer allowed
|
// Don't bother with basic auth, since it's no longer allowed
|
||||||
if (!empty($flink) && TwitterOAuthClient::isPackedToken($flink->credentials)) {
|
if (!empty($flink) && TwitterOAuthClient::isPackedToken($flink->credentials)) {
|
||||||
|
if (is_twitter_bound($notice, $flink)) {
|
||||||
if (!empty($notice->repeat_of) && is_twitter_notice($notice->repeat_of)) {
|
if (!empty($notice->repeat_of) && is_twitter_notice($notice->repeat_of)) {
|
||||||
$retweet = retweet_notice($flink, Notice::staticGet('id', $notice->repeat_of));
|
$retweet = retweet_notice($flink, Notice::staticGet('id', $notice->repeat_of));
|
||||||
if (is_object($retweet)) {
|
if (is_object($retweet)) {
|
||||||
@ -183,10 +184,11 @@ function broadcast_twitter($notice)
|
|||||||
// this or can discard safely.
|
// this or can discard safely.
|
||||||
return $retweet;
|
return $retweet;
|
||||||
}
|
}
|
||||||
} else if (is_twitter_bound($notice, $flink)) {
|
} else {
|
||||||
return broadcast_oauth($notice, $flink);
|
return broadcast_oauth($notice, $flink);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user