Skip to content

Commit

Permalink
fix: add optional chaining for pod labels in AppMetrics component
Browse files Browse the repository at this point in the history
  • Loading branch information
AbhishekA1509 committed Dec 12, 2024
1 parent d0a54d0 commit 3984b81
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/app/details/appDetails/AppMetrics.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ export const AppMetrics: React.FC<{
})
const addSpace: string = addExtraSpace ? 'mb-16' : ''
const pod = podMap?.values().next().value
const newPodHash = pod?.networkingInfo?.labels['rollouts-pod-template-hash']
const newPodHash = pod?.networkingInfo?.labels?.['rollouts-pod-template-hash']

function handleTabChange(event): void {
const tab = event.target.value
Expand Down

0 comments on commit 3984b81

Please sign in to comment.