summaryrefslogtreecommitdiff
path: root/lib/util.php
diff options
context:
space:
mode:
authorZach Copley <zach@controlyourself.ca>2008-09-23 04:36:32 -0400
committerZach Copley <zach@controlyourself.ca>2008-09-23 04:36:32 -0400
commit04b95c25add9b1aafd011713b1b6b7a67f49f9f2 (patch)
tree3b6ad43df0b38426368ac203120081ae2c7c72ca /lib/util.php
parentc9c2d375ba55332cd96fc28bb0569db3131916b9 (diff)
Twitter bridge: Hack to get around PHP cURL's use of @ as a metachar,
which was keeping @reply messages from getting posted to Twitter. darcs-hash:20080923083632-7b5ce-02498acc9fba3070b984eb473ec7825a5eaa2a77.gz
Diffstat (limited to 'lib/util.php')
-rw-r--r--lib/util.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/util.php b/lib/util.php
index 453149305..86b2747dc 100644
--- a/lib/util.php
+++ b/lib/util.php
@@ -1129,7 +1129,9 @@ function common_twitter_broadcast($notice, $flink) {
$twitter_user = $fuser->nickname;
$twitter_password = $flink->credentials;
$uri = 'http://www.twitter.com/statuses/update.json';
- $statustxt = $notice->content;
+
+ // XXX: Hack to get around PHP cURL's use of @ being a a meta character
+ $statustxt = preg_replace('/^@/', ' @', $notice->content);
$options = array(
CURLOPT_USERPWD => "$twitter_user:$twitter_password",