Skip to content

Commit

Permalink
Use ??= more
Browse files Browse the repository at this point in the history
  • Loading branch information
nicolas-grekas committed Nov 2, 2022
1 parent 1a48159 commit 5602fcc
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions CookieJar.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,7 @@ public function get(string $name, string $path = '/', string $domain = null): ?C
*/
public function expire(string $name, ?string $path = '/', string $domain = null)
{
if (null === $path) {
$path = '/';
}
$path ??= '/';

if (empty($domain)) {
// an empty domain means any domain
Expand Down

0 comments on commit 5602fcc

Please sign in to comment.