add versions for url-shortener plugins

This commit is contained in:
Evan Prodromou
2010-01-08 00:20:38 -08:00
parent 505cd382f3
commit 054aaa40bf
5 changed files with 66 additions and 3 deletions

View File

@@ -47,5 +47,18 @@ class SimpleUrlPlugin extends UrlShortenerPlugin
protected function shorten($url) {
return $this->http_get(sprintf($this->serviceUrl,urlencode($url)));
}
function onPluginVersion(&$versions)
{
$versions[] = array('name' => sprintf('SimpleUrl (%s)', $this->shortenerName),
'version' => STATUSNET_VERSION,
'author' => 'Craig Andrews',
'homepage' => 'http://status.net/wiki/Plugin:SimpleUrl',
'rawdescription' =>
sprintf(_m('Uses <a href="http://%1$s/">%1$s</a> URL-shortener service.'),
$this->shortenerName));
return true;
}
}