Add error display for status panel failures
Build and Push Docker Image / build (push) Successful in 50s
Licence Check / Licence compatibility and copyright header verification (push) Successful in 1m8s
CI / Security audit (push) Successful in 1m20s
CI / Tests & coverage (push) Has been cancelled

- Show error message when status API returns error (e.g., 403 for non-admin)
- Helps debug why status panel appears empty
This commit is contained in:
2026-05-21 01:37:31 +01:00
parent 14b47ce410
commit b3664747cb
+5
View File
@@ -49,6 +49,11 @@ export async function refreshStatusPanel() {
if (result.success) {
console.log('[Status] Got status data, rendering...');
renderStatusPanel(result.data, panel);
} else {
console.error('[Status] API returned error:', result.error);
if (contentDiv && (!contentDiv.innerHTML || contentDiv.innerHTML.includes('status-loading'))) {
contentDiv.innerHTML = '<p class="status-error">Failed to load status: ' + result.error + '</p>';
}
}
} catch (err) {
console.error('[Status] Error fetching status:', err);