Skip to content

Commit cec5e73

Browse files
authored
Merge pull request #138 from gianlucam76/release-1.2
(bug) fix crash when ClusterAPI Spec.Topology is nil
2 parents 2ca96e5 + faa7712 commit cec5e73

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

internal/server/manager.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,9 @@ func (m *instance) AddCAPICluster(cluster *clusterv1.Cluster) {
273273
FailureMessage: examineClusterConditions(cluster),
274274
}
275275

276-
info.Version = cluster.Spec.Topology.Version
276+
if cluster.Spec.Topology != nil {
277+
info.Version = cluster.Spec.Topology.Version
278+
}
277279

278280
clusterInfo := getKeyFromObject(m.scheme, cluster)
279281

0 commit comments

Comments
 (0)