]> git.mxchange.org Git - friendica.git/blobdiff - mod/pubsubhubbub.php
Curl Response Refactoring
[friendica.git] / mod / pubsubhubbub.php
index 5697be8305bdb1c94e6f7a3be99a656bbff2b25f..d7b204e89c4f9622e081fd30507673eb729b94e2 100644 (file)
@@ -104,8 +104,9 @@ function pubsubhubbub_init(App $a) {
                // we don't actually enforce the lease time because GNU
                // Social/StatusNet doesn't honour it (yet)
 
-               $body = Network::fetchUrl($hub_callback . "?" . $params);
-               $ret = Network::getCurl()->getCode();
+               $fetchResult = Network::fetchUrlFull($hub_callback . "?" . $params);
+               $body = $fetchResult->getBody();
+               $ret = $fetchResult->getReturnCode();
 
                // give up if the HTTP return code wasn't a success (2xx)
                if ($ret < 200 || $ret > 299) {