summaryrefslogtreecommitdiff
path: root/plugins/TwitterBridge/daemons/twitterstatusfetcher.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@status.net>2010-09-05 00:32:56 -0400
committerEvan Prodromou <evan@status.net>2010-09-07 04:00:58 -0400
commit702d36257c6edb1e4f87087c60f1a534fc69a918 (patch)
tree6679c4962b23a6598bf78debb4f05e96a580110d /plugins/TwitterBridge/daemons/twitterstatusfetcher.php
parent9847bffe998544ee8aa284849134e86e3c4c598a (diff)
truncate retweeted stuff if it's too long
Diffstat (limited to 'plugins/TwitterBridge/daemons/twitterstatusfetcher.php')
-rwxr-xr-xplugins/TwitterBridge/daemons/twitterstatusfetcher.php6
1 files changed, 6 insertions, 0 deletions
diff --git a/plugins/TwitterBridge/daemons/twitterstatusfetcher.php b/plugins/TwitterBridge/daemons/twitterstatusfetcher.php
index 6f0bddd04..e897cc6ea 100755
--- a/plugins/TwitterBridge/daemons/twitterstatusfetcher.php
+++ b/plugins/TwitterBridge/daemons/twitterstatusfetcher.php
@@ -274,6 +274,12 @@ class TwitterStatusFetcher extends ParallelizingDaemon
$content = sprintf(_('RT @%1$s %2$s'),
$author->nickname,
$original->content);
+
+ if (Notice::contentTooLong($content)) {
+ $contentlimit = Notice::maxContent();
+ $content = mb_substr($content, 0, $contentlimit - 4) . ' ...';
+ }
+
$repeat = Notice::saveNew($profile->id,
$content,
'twitter',