summaryrefslogtreecommitdiff
path: root/plugins/DirectionDetector
diff options
context:
space:
mode:
authorSiebrand Mazeland <s.mazeland@xs4all.nl>2010-10-18 22:11:33 +0200
committerSiebrand Mazeland <s.mazeland@xs4all.nl>2010-10-18 22:11:33 +0200
commit3c10602561006f30bfdf83759690b05ae90e3e36 (patch)
tree5ba985b9ba10c85972b1acbb84e130c427d2d49a /plugins/DirectionDetector
parente6df1b19dfaf8424c612efe56af442f37863ffff (diff)
parentaa80d8fee3865e25e8d47a5c83b6575ca3dc79ea (diff)
Merge branch '0.9.x' of git://gitorious.org/statusnet/mainline into 0.9.x
Diffstat (limited to 'plugins/DirectionDetector')
-rw-r--r--plugins/DirectionDetector/DirectionDetectorPlugin.php3
1 files changed, 3 insertions, 0 deletions
diff --git a/plugins/DirectionDetector/DirectionDetectorPlugin.php b/plugins/DirectionDetector/DirectionDetectorPlugin.php
index 1473c386f..4a38f390f 100644
--- a/plugins/DirectionDetector/DirectionDetectorPlugin.php
+++ b/plugins/DirectionDetector/DirectionDetectorPlugin.php
@@ -81,6 +81,9 @@ class DirectionDetectorPlugin extends Plugin {
* @return boolean
*/
public static function startsWithRTLCharacter($str){
+ if (strlen($str) < 1) {
+ return false;
+ }
if( is_array($cc = self::utf8ToUnicode(mb_substr($str, 0, 1, 'utf-8'))) )
$cc = $cc[0];
else