Permalink
Browse files

Prepping 3.9.2 release

  • Loading branch information...
1 parent 978b2d6 commit 1e8dd1e2ba9dc42332396f39fbfab950b2301dc5 @mtdowling mtdowling committed Aug 11, 2014
Showing with 8 additions and 8 deletions.
  1. +8 −8 Client.php
View
@@ -504,14 +504,14 @@ public static function extractPharCacert($pharCacertPath)
// folder.
$certFile = sys_get_temp_dir() . '/guzzle-cacert.pem';
- if (!file_exists($certFile)) {
- if (!file_exists($pharCacertPath)) {
- throw new \RuntimeException("Could not find $pharCacertPath");
- }
- // Only copy when the file size is different
- if (filesize($certFile) != filesize($pharCacertPath)
- && !copy($pharCacertPath, $certFile)
- ) {
+ if (!file_exists($pharCacertPath)) {
+ throw new \RuntimeException("Could not find $pharCacertPath");
+ }
+
+ if (!file_exists($certFile) ||
+ filesize($certFile) != filesize($pharCacertPath)
+ ) {
+ if (!copy($pharCacertPath, $certFile)) {
throw new \RuntimeException(
"Could not copy {$pharCacertPath} to {$certFile}: "
. var_export(error_get_last(), true)

0 comments on commit 1e8dd1e

Please sign in to comment.