Show qBittorrent auth response in error message for debugging
ci/woodpecker/push/woodpecker Pipeline was successful

This commit is contained in:
2026-05-20 19:15:24 +02:00
parent be16444e93
commit dfcce073db
+1 -1
View File
@@ -21,7 +21,7 @@ async function getCookie(): Promise<string> {
) )
const cookie = (res.headers['set-cookie'] ?? []).find((c: string) => c.startsWith('SID=')) const cookie = (res.headers['set-cookie'] ?? []).find((c: string) => c.startsWith('SID='))
if (!cookie || res.data === 'Fails.') throw new Error('qBittorrent login failed') if (!cookie) throw new Error(`qBittorrent login failed: ${String(res.data).trim()}`)
sid = cookie.split(';')[0] sid = cookie.split(';')[0]
sidExpiry = Date.now() + 55 * 60 * 1000 sidExpiry = Date.now() + 55 * 60 * 1000