]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - lib/facebookaction.php
Merge branch '0.8.x' into 0.9.x
[quix0rs-gnu-social.git] / lib / facebookaction.php
index 289e702c6958d332fd6cd7b10900e692a9e543be..4edd3a077cd34825036b5b6c122202d50dd96835 100644 (file)
@@ -35,7 +35,6 @@ if (!defined('LACONICA'))
 require_once INSTALLDIR.'/lib/facebookutil.php';
 require_once INSTALLDIR.'/lib/noticeform.php';
 
-
 class FacebookAction extends Action
 {
 
@@ -180,7 +179,6 @@ class FacebookAction extends Action
 
     }
 
-
     // Make this into a widget later
     function showLocalNav()
     {
@@ -240,7 +238,6 @@ class FacebookAction extends Action
         $this->endHTML();
     }
 
-
     function showInstructions()
     {
 
@@ -271,7 +268,6 @@ class FacebookAction extends Action
         $this->elementEnd('div');
     }
 
-
     function showLoginForm($msg = null)
     {
 
@@ -316,7 +312,6 @@ class FacebookAction extends Action
 
     }
 
-
     function updateProfileBox($notice)
     {
 
@@ -398,7 +393,6 @@ class FacebookAction extends Action
         $this->xw->openURI('php://output');
     }
 
-
     /**
      * Generate pagination links
      *
@@ -457,8 +451,9 @@ class FacebookAction extends Action
         } else {
             $content_shortened = common_shorten_links($content);
 
-            if (mb_strlen($content_shortened) > 140) {
-                $this->showPage(_('That\'s too long. Max notice size is 140 chars.'));
+            if (Notice::contentTooLong($content_shortened)) {
+                $this->showPage(sprintf(_('That\'s too long. Max notice size is %d chars.'),
+                                        Notice::maxContent()));
                 return;
             }
         }