fix(13): WR-06 read result.status (not result.state) in testConnection to reflect actual server field name
This commit is contained in:
@@ -251,7 +251,9 @@ export const useCloudConnectionsStore = defineStore('cloudConnections', () => {
|
||||
async function testConnection(id) {
|
||||
try {
|
||||
const result = await api.testCloudConnection(id)
|
||||
const state = result?.state ?? 'unknown'
|
||||
// WR-06: server returns { status: ... }, not { state: ... }. Translate at the
|
||||
// store boundary — internal vocabulary uses `state` but the API field is `status`.
|
||||
const state = result?.status ?? 'unknown'
|
||||
setConnectionHealth(id, { state, ...result })
|
||||
// Clear pending retest flag for this connection
|
||||
const next = new Set(pendingHealthRetest.value)
|
||||
|
||||
Reference in New Issue
Block a user