Skip to content

fix(ocm): prevent error when ManagedCluster.status doesn't contain a 'clusterClaims' field #1324

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 11, 2024

Conversation

jesuino
Copy link
Contributor

@jesuino jesuino commented Mar 8, 2024

Error:
When a ManagerCluster API response lacks the status.clusterClaims then the error Cannot read properties of undefined (reading 'find') is displayed on the UI.

Fix: Just make sure that clusterClaims is checked before calling find ;

@jesuino jesuino requested a review from a team as a code owner March 8, 2024 17:50
@jesuino jesuino requested a review from PatAKnight March 8, 2024 17:50
Copy link

sonarqubecloud bot commented Mar 8, 2024

Quality Gate Passed Quality Gate passed

Issues
4 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@invincibleJai
Copy link
Member

/lgtm
/approve

Copy link

openshift-ci bot commented Mar 11, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: invincibleJai

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants