*
* @return string response body
*
- * @todo self with exceptions as in httpGet()
*/
protected function httpPost($url, $data)
{
- try{
- $request = HTTPClient::start();
- $response = $request->post($url, null, $data);
-
- } catch(PluginErrorException $e)
- {
- $e->printFull();
- return false;
- }
+
+ $request = HTTPClient::start();
+ $response = $request->post($url, null, $data);
return $response->getBody();
}
// Hook handlers
{
$shortenedUrl = $result;
//dont create an exception, so we can do that without.
- //If needed, i can code done..but actually it seems useless to do that.
common_log(LOG_INFO,
__CLASS__ . ": $this->shortenerName ".
"shortened $url to $shortenedUrl");