diff --git a/src/CryptoEncoding/PEM.php b/src/CryptoEncoding/PEM.php index 53b46cd5..8d02c560 100644 --- a/src/CryptoEncoding/PEM.php +++ b/src/CryptoEncoding/PEM.php @@ -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)); } diff --git a/src/CryptoEncoding/PEMBundle.php b/src/CryptoEncoding/PEMBundle.php index 81c90fd5..5ca7a544 100644 --- a/src/CryptoEncoding/PEMBundle.php +++ b/src/CryptoEncoding/PEMBundle.php @@ -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)); }