-
Notifications
You must be signed in to change notification settings - Fork 159
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
Filter sidebar shares for displayName #9504
Conversation
return [...this.outgoingCollaborators] | ||
.filter((c) => c.collaborator.displayName) | ||
.sort(this.collaboratorsComparator) | ||
.map((c) => { | ||
const collaborator: typeof c & { key?: string; resharers?: User[] } = { ...c } | ||
collaborator.key = 'collaborator-' + collaborator.id | ||
if ( | ||
collaborator.owner.name !== collaborator.fileOwner.name && | ||
collaborator.owner.name !== this.user.id | ||
) { | ||
collaborator.resharers = [collaborator.owner] | ||
} | ||
return collaborator | ||
}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd prefer adding the filter to outgoingCollaborators
in our useShare
composable.
I guess this is CERN specific? We can also think about overwriting the composable via cern config like we did here. Although it's such a small change, it's probably not worth the effort 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm open to doing that, the benefit of doing it here is that one could also add some sort of hint to the UI about further shares existing but the webUI not being able to correctly render these (whcih technically could also be done inside the composable and then exported, ofc). Let me discuss this with @tbsbdr
5d24e3d
to
d8d609d
Compare
Kudos, SonarCloud Quality Gate passed! |
* Fix #9257 * Move filtering for collaborator displayName in outgoingShares to useShares composable
* Fix #9257 * Move filtering for collaborator displayName in outgoingShares to useShares composable
Related Issue