rewrote short url stuff to handle new file/url classes (redirections, oembed, mimetypes, etc.)

This commit is contained in:
Robin Millette
2009-05-13 14:27:32 -04:00
parent d010d811ba
commit 3b7ee5a5f9
10 changed files with 383 additions and 237 deletions

View File

@@ -22,6 +22,7 @@ if (!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) >= $this->long_limit;
}
protected function http_post($data) {