fix(realdebrid): persist web status and report relevant provider errors
Check Real-Debrid API and browser sessions through the account status flow, retain the service status across settings updates, and refresh the account row when a browser login is detected. Exclude unavailable providers that were never attempted from conversion failures and prevent aggregated fallback text from being mislabeled as a Debrid-Link terminal error. Bump the development version to 2.0.37 and add focused regression coverage.
This commit is contained in:
@@ -2359,16 +2359,17 @@ export function App(): ReactElement {
|
||||
}
|
||||
});
|
||||
}
|
||||
} else {
|
||||
rows.push({
|
||||
} else {
|
||||
const serviceAccountId = entry.service === "realdebrid" ? "svc-realdebrid" : null;
|
||||
rows.push({
|
||||
rowKey: `svc-${entry.service}`,
|
||||
entry,
|
||||
hosterLabel: entry.serviceLabel,
|
||||
modeLabel: entry.modeLabel,
|
||||
username: getStoredAccountUsername(entry.kind, snapshot.accounts),
|
||||
credentialLabel: getAccountCredentialLabel(entry.kind),
|
||||
accountId: null,
|
||||
checkable: false,
|
||||
accountId: serviceAccountId,
|
||||
checkable: serviceAccountId !== null,
|
||||
disabled: entry.disabled,
|
||||
dailyUsedBytes: entry.dailyUsedBytes,
|
||||
dailyLimitBytes: entry.dailyLimitBytes,
|
||||
@@ -2653,8 +2654,8 @@ export function App(): ReactElement {
|
||||
setAccountCheckBusy(true);
|
||||
try {
|
||||
const statuses = await window.rd.checkDebridAccounts();
|
||||
if (!statuses || statuses.length === 0) {
|
||||
showToast("Keine Mega-Debrid-/Debrid-Link-Accounts zum Prüfen konfiguriert.", 3200);
|
||||
if (!statuses || statuses.length === 0) {
|
||||
showToast("Keine prüfbaren Accounts konfiguriert.", 3200);
|
||||
} else {
|
||||
const valid = statuses.filter((st) => st.valid).length;
|
||||
const premium = statuses.filter((st) => st.isPremium).length;
|
||||
@@ -2941,7 +2942,7 @@ export function App(): ReactElement {
|
||||
|
||||
const checkAccountTableRow = (row: AccountTableRow): void => {
|
||||
setAccountContextMenu(null);
|
||||
if (row.toggleKind === "mega" || row.toggleKind === "dl") {
|
||||
if (row.checkable) {
|
||||
void checkAllAccounts();
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user