fix: remove declaracao duplicada de rawInventory
All checks were successful
CI/CD Web + Desktop / Detect changes (push) Successful in 4s
Quality Checks / Lint, Test and Build (push) Successful in 3m12s
CI/CD Web + Desktop / Deploy (VPS Linux) (push) Successful in 3m18s
CI/CD Web + Desktop / Deploy Convex functions (push) Successful in 1m41s

This commit is contained in:
rever-tecnologia 2025-12-18 09:56:26 -03:00
parent db23ea1901
commit dc740cd89a

View file

@ -1091,7 +1091,7 @@ export const heartbeat = mutation({
// Processar softwares instalados (armazenados em tabela separada) // Processar softwares instalados (armazenados em tabela separada)
// Os dados de software sao extraidos ANTES de sanitizar o inventory // Os dados de software sao extraidos ANTES de sanitizar o inventory
const rawInventory = args.inventory ?? args.metadata?.inventory // Usa rawInventory ja extraido anteriormente (linha ~1022)
if (rawInventory && typeof rawInventory === "object") { if (rawInventory && typeof rawInventory === "object") {
const softwareArray = (rawInventory as Record<string, unknown>)["software"] const softwareArray = (rawInventory as Record<string, unknown>)["software"]
if (Array.isArray(softwareArray) && softwareArray.length > 0) { if (Array.isArray(softwareArray) && softwareArray.length > 0) {