This commit is contained in:
salam committed 2026-11-01 18:26:58 +01:00
1 parent f3245d40cc
commit 5a8161fb8d
1 file changed
+4 -2
+4 -2
View File
@@ -180,14 +180,16 @@ trait PlayerQuery
{
switch ($this->season_or_date) {
case 'season':
if (! $this->season_selected) {
$this->season_selected = $this->getCurrentSeason();
}
if ($this->season_mode == 'fullyear') {
// Keeps elements where '/' is FALSE
$this->season_selected = array_filter($this->season_selected, fn ($item) => ! str_contains($item, '/'));
$this->season_selected = array_map('intval', $this->season_selected);
} else {
// Keeps elements ONLY if '/' returns TRUE
$this->season_selected = array_filter($this->season_selected, fn ($item) => str_contains($item, '/'));
$this->season_selected = array_map('strval', $this->season_selected);
}