diff --git a/skills/aliyun-ecs-skill/src/index.js b/skills/aliyun-ecs-skill/src/index.js index c68d7aebe45..05aec91f968 100755 --- a/skills/aliyun-ecs-skill/src/index.js +++ b/skills/aliyun-ecs-skill/src/index.js @@ -34,7 +34,8 @@ function formatTable(data, columns) { data.forEach(row => { output += '|'; columns.forEach(col => { - const value = String(row[col.key] || '-'); + const cellValue = row[col.key]; + const value = String(cellValue !== undefined && cellValue !== null ? cellValue : '-'); output += ` ${value.padEnd(widths[col.key] - 1)}|`; }); output += '\n';