X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=lib%2FShorturl_api.php;h=6402dbc099615918d7ee777330b61abfe3c8873b;hb=a5ed805aeabab3930d066b2777dbab9663bc487f;hp=fe106cb8376a06b69ac5ba142329917b808a4427;hpb=b264c03d32d04d7a33d28a5830848660f4484943;p=quix0rs-gnu-social.git diff --git a/lib/Shorturl_api.php b/lib/Shorturl_api.php index fe106cb837..6402dbc099 100644 --- a/lib/Shorturl_api.php +++ b/lib/Shorturl_api.php @@ -1,7 +1,7 @@ . */ -if (!defined('LACONICA')) { exit(1); } +if (!defined('STATUSNET') && !defined('LACONICA')) { exit(1); } class ShortUrlApi { protected $service_url; + protected $long_limit = 27; function __construct($service_url) { @@ -39,7 +40,7 @@ class ShortUrlApi } private function is_long($url) { - return strlen($url) >= 30; + return strlen($url) >= common_config('site', 'shorturllength'); } protected function http_post($data) {