Skip to content

Commit

Permalink
Provide enclosure character for str_getcsv
Browse files Browse the repository at this point in the history
With PHP 8.4 `str_getcsv` will require a single character to be provided as enclosure. Passing an empty string results in 
```
ValueError: str_getcsv(): Argument #3 ($enclosure) must be a single character
```
  • Loading branch information
sgiehl authored Oct 15, 2024
1 parent 500a1f7 commit 132e7a3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion BlockedIpRanges/DigitalOcean.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public function getRanges(): array
return [];
}

$digitalOcean = str_getcsv($digitalOcean['data'], ',', '');
$digitalOcean = str_getcsv($digitalOcean['data'], ',', '"');

if (empty($digitalOcean)) {
throw new \Exception('Failed to parse digital ocean IP ranges');
Expand Down

0 comments on commit 132e7a3

Please sign in to comment.