diff --git a/classes/Betterrest.php b/classes/Betterrest.php index 612f90e..ee75f75 100644 --- a/classes/Betterrest.php +++ b/classes/Betterrest.php @@ -206,7 +206,7 @@ private function optionsFromQuery(?array $query = null): array } if ($srcset = \Kirby\Toolkit\A::get($query, 'br-srcset')) { $srcset = str_replace([' ', '%20'], ['', ''], (string) $srcset); - $optionsFromQuery['srcset'] = in_array($srcset, ['false', '0', 'null']) ? null : explode(',', $srcset); + $optionsFromQuery['srcset'] = in_array($srcset, ['false', '0', 'null']) ? null : array_map(static function($v) { return intval($v); }, explode(',', $srcset)); } return $optionsFromQuery; diff --git a/composer.json b/composer.json index a25c576..6688c89 100755 --- a/composer.json +++ b/composer.json @@ -2,7 +2,7 @@ "name": "robinscholz/better-rest", "description": "Kirby Plugin for better REST requests", "type": "kirby-plugin", - "version": "1.2.4", + "version": "1.2.5", "license": "MIT", "authors": [ {