Copilot commented on code in PR #48509:
URL: https://github.com/apache/airflow/pull/48509#discussion_r2019358329
##########
airflow-core/src/airflow/ui/src/components/DagVersionDetails.tsx:
##########
@@ -30,8 +30,8 @@ export const DagVersionDetails = ({ dagVersion }: { readonly
dagVersion?: DagVer
<Table.Root striped>
<Table.Body>
<Table.Row>
- <Table.Cell>Version Number</Table.Cell>
- <Table.Cell>{dagVersion.version_number ?
`v${dagVersion.version_number}` : "unknown"}</Table.Cell>
+ <Table.Cell>Version ID</Table.Cell>
+ <Table.Cell>{dagVersion.id}</Table.Cell>
Review Comment:
The direct use of dagVersion.id does not provide a fallback value, which
might lead to empty displays if the id is undefined. Consider adding a fallback
(e.g., using a ternary operator to default to 'unknown') similar to the
previous version_number logic.
```suggestion
<Table.Cell>{dagVersion.id ?? 'unknown'}</Table.Cell>
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]