Skip to content
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

Fix loading/editing users that do not have a role assignment #8590

Merged
merged 3 commits into from Mar 10, 2023

Conversation

JammingBen
Copy link
Collaborator

Related Issue

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Technical debt
  • Tests

@JammingBen JammingBen self-assigned this Mar 10, 2023
@AlexAndBear
Copy link
Contributor

How does this happen, in which case a user doesn't have a role? This is quite new to me.

@JammingBen
Copy link
Collaborator Author

You can test this by running oCIS locally and clearing the metadata folder on your storage. I can't give you a real-world example though, maybe @micbar knows more about that.

But as the field can be empty and the API allows that, I guess we shouldn't assume that it's always set.

@AlexAndBear
Copy link
Contributor

image

image

We might want to show a '-' in the details and also in the table

@JammingBen
Copy link
Collaborator Author

We might want to show a '-' in the details and also in the table

Agreed, also keeps it compatible with the Quota field 👍

@sonarcloud
Copy link

sonarcloud bot commented Mar 10, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

72.7% 72.7% Coverage
0.0% 0.0% Duplication

@AlexAndBear AlexAndBear merged commit 04ddb85 into master Mar 10, 2023
4 checks passed
@delete-merged-branch delete-merged-branch bot deleted the fix-users-with-empty-role branch March 10, 2023 12:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

User Management should not break when role is empty
2 participants