OverviewFilesCommitsIssuesDocsReleasesPeers

pear-git commits / ce2eb6e

Fix: parse arch query param from req.url (no framework query parser)
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
ce2eb6ea8aed45627eefab9cedd2f7b493eda931
by plankatron <fleeky@gmail.com> · 2026-04-07T12:52:34.000Z

Changed files (1) +3 -1

lib/routes/archive.js +3 -1
……@@ -82,7 +82,9 @@ async function handleArchiveDownload (req, res, server) {
8282 }
8383
8484 // 4. Resolve archive path (arch-specific if ?arch= query param)
85 const arch = req.query ? req.query.arch : null
85 const urlQuery = (req.url || '').split('?')[1] || ''
86 const archMatch = urlQuery.match(/arch=([^&]+)/)
87 const arch = archMatch ? archMatch[1] : null
8688 const storagePath = path.resolve(storage || './pear-git-storage')
8789 const archiveDir = path.join(storagePath, 'archives')
8890 const archSuffix = arch ? `-${arch}` : ''