mirror of
https://github.com/kikootwo/ReadMeABook.git
synced 2026-07-14 16:51:10 +00:00
Optional qBittorrent creds; require SABnzbd key
Allow qBittorrent to be configured without credentials (supports IP whitelist) and require an API key for SABnzbd. Skip connection testing when disabling a client. Updates include: validation changes in admin and setup API routes, test-download-client flows, DownloadClientModal UI validation and save/test logic, and DownloadClientManager to pass empty strings for optional credentials. Tests updated to reflect SABnzbd API key requirement.
This commit is contained in:
@@ -77,12 +77,16 @@ export async function PUT(
|
||||
}
|
||||
}
|
||||
|
||||
// Test connection if credentials/URL changed
|
||||
// Test connection if credentials/URL changed (skip if disabling client)
|
||||
const isDisabling = enabled === false;
|
||||
if (
|
||||
url !== undefined ||
|
||||
username !== undefined ||
|
||||
(password && password !== '********') ||
|
||||
disableSSLVerify !== undefined
|
||||
!isDisabling &&
|
||||
(
|
||||
url !== undefined ||
|
||||
username !== undefined ||
|
||||
(password && password !== '********') ||
|
||||
disableSSLVerify !== undefined
|
||||
)
|
||||
) {
|
||||
const testResult = await manager.testConnection(updatedClient);
|
||||
if (!testResult.success) {
|
||||
|
||||
Reference in New Issue
Block a user