Skip to content

Commit 22ce4b5

Browse files
Merge pull request #16 from stanley-cheung/update-to-1_26
Update to v1.26
2 parents bdb165d + fbe4513 commit 22ce4b5

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"keywords": ["rpc"],
66
"homepage": "https://grpc.io",
77
"license": "Apache-2.0",
8-
"version": "1.25.0",
8+
"version": "1.26.0",
99
"require": {
1010
"php": ">=5.5.0"
1111
},

src/lib/BaseStub.php

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,10 +43,12 @@ class BaseStub
4343
*/
4444
public function __construct($hostname, $opts, $channel = null)
4545
{
46-
$ssl_roots = file_get_contents(
47-
dirname(__FILE__).'/../../etc/roots.pem'
48-
);
49-
ChannelCredentials::setDefaultRootsPem($ssl_roots);
46+
if (!ChannelCredentials::isDefaultRootsPemSet()) {
47+
$ssl_roots = file_get_contents(
48+
dirname(__FILE__).'/../../../../etc/roots.pem'
49+
);
50+
ChannelCredentials::setDefaultRootsPem($ssl_roots);
51+
}
5052

5153
$this->hostname = $hostname;
5254
$this->update_metadata = null;

0 commit comments

Comments
 (0)