Skip to content

Commit

Permalink
Fix two warnings during unit-testing
Browse files Browse the repository at this point in the history
  • Loading branch information
tvdijen committed Jul 30, 2024
1 parent a2ac09c commit 61dee42
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/CryptoEncoding/PEM.php
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ public static function fromFile(string $filename): self

if (!is_readable($filename) || ($str === false)) {
$e = error_get_last();
$error = $e['message'] ?: "Check that the file exists and can be read.";
$error = $e['message'] ?? "Check that the file exists and can be read.";
throw new IOException(sprintf("File '%s' was not loaded; %s", $filename, $error));
}

Expand Down
2 changes: 1 addition & 1 deletion src/CryptoEncoding/PEMBundle.php
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ public static function fromFile(string $filename): self

if (!is_readable($filename) || ($str === false)) {
$e = error_get_last();
$error = $e['message'] ?: "Check that the file exists and can be read.";
$error = $e['message'] ?? "Check that the file exists and can be read.";
throw new IOException(sprintf("File '%s' was not loaded; %s", $filename, $error));
}

Expand Down

0 comments on commit 61dee42

Please sign in to comment.