git.cweiske.de
/
shpub.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
add option to list all configured server connections
[shpub.git]
/
src
/
shpub
/
Command
/
Like.php
diff --git
a/src/shpub/Command/Like.php
b/src/shpub/Command/Like.php
index 70e836f50b1f0ea95c06ab76132ee76b4fc08f57..8baeee7e70901d47673ab2fb85941a14309cf72a 100644
(file)
--- a/
src/shpub/Command/Like.php
+++ b/
src/shpub/Command/Like.php
@@
-28,6
+28,11
@@
class Command_Like
);
$req = new \HTTP_Request2($this->host->endpoints->micropub, 'POST');
);
$req = new \HTTP_Request2($this->host->endpoints->micropub, 'POST');
+ if (version_compare(PHP_VERSION, '5.6.0', '<')) {
+ //correct ssl validation on php 5.5 is a pain, so disable
+ $req->setConfig('ssl_verify_host', false);
+ $req->setConfig('ssl_verify_peer', false);
+ }
$req->setHeader('Content-type', 'application/x-www-form-urlencoded');
$req->setHeader('Authorization', 'Bearer ' . $this->host->token);
$req->setBody($body);
$req->setHeader('Content-type', 'application/x-www-form-urlencoded');
$req->setHeader('Authorization', 'Bearer ' . $this->host->token);
$req->setBody($body);