Skip to content

Commit ffdb548

Browse files
committed
Remove dead code: unreachable return false and file_put_contents failure path
1 parent 619816f commit ffdb548

2 files changed

Lines changed: 1 addition & 7 deletions

File tree

src/Endpoints/DomainValidation.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -181,8 +181,6 @@ public function allChallengesPassed(OrderData $orderData): bool
181181
$this->client->logger('info', "Challenge is not valid yet. Another attempt in {$delay} seconds.");
182182
sleep($delay);
183183
}
184-
185-
return false;
186184
}
187185

188186
/** @param DomainValidationData[] $domainValidation */

src/Storage/FilesystemStorage.php

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -171,11 +171,7 @@ private function writeFile(string $path, string $contents): void
171171
);
172172
}
173173

174-
if (file_put_contents($path, $contents, LOCK_EX) === false) {
175-
throw new StorageException(
176-
sprintf('Could not write storage file "%s".', $path)
177-
);
178-
}
174+
file_put_contents($path, $contents, LOCK_EX);
179175

180176
// Restrict private key files to owner-read-only.
181177
if (str_ends_with($path, '.pem')) {

0 commit comments

Comments
 (0)