[web-downloads] main: Fix check in GetListing::handle
| From: | Shivam Mathur | Date: | Thu, 02 Apr 2026 01:28:01 +0000 |
| Subject: | [web-downloads] main: Fix check in GetListing::handle | ||
| Groups: | php.webmaster | ||
| Request: | Send a blank email to php-webmaster+get-33635@lists.php.net to get a copy of this message | ||
Author: Shivam Mathur (shivammathur)
Date: 2026-04-02T06:22:54+05:30
Commit: https://github.com/php/web-downloads/commit/97882c07b56b54b5a317663a075aeb5649c87324
Raw diff: https://github.com/php/web-downloads/commit/97882c07b56b54b5a317663a075aeb5649c87324.diff
Fix check in GetListing::handle
Changed paths:
M src/Actions/GetListing.php
Diff:
diff --git a/src/Actions/GetListing.php b/src/Actions/GetListing.php
index 014f6fd..5194809 100644
--- a/src/Actions/GetListing.php
+++ b/src/Actions/GetListing.php
@@ -22,7 +22,7 @@ public function handle(string $directory): array
$parts = $this->parseFileName(basename($file));
$key = ($parts['nts'] ? 'nts-' : 'ts-') .
$parts['vc'] . '-' . $parts['arch'];
$version_short = $parts['version_short'];
- if (!isset($releases['version'])) {
+ if (!isset($releases[$version_short]['version'])) {
$releases[$version_short]['version'] = $parts['version'];
}
$releases[$version_short][$key]['mtime'] = $mtime;