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

feat: 🍰 Implement Group Profile – Visibility #5332

Merged
merged 9 commits into from
Sep 15, 2022

Conversation

Tirokk
Copy link
Member

@Tirokk Tirokk commented Sep 9, 2022

🍰 Pull Request

Implement group profile – second step.

Issues

Todo

  • hidden groups can only be seen by members that are not pending
  • cleanup:
    • search Wolle

…e-or-pending-members' of github.com:Ocelot-Social-Community/Ocelot-Social into 5059-groups/5318-group-profile-second
…/Ocelot-Social into 5059-groups/5318-group-profile-second
@Tirokk Tirokk changed the base branch from master to 5059-epic-groups September 9, 2022 11:55
@Tirokk Tirokk changed the title feat: [WIP] 🍰 Implement Group Profile – Second Step feat: 🍰 Implement Group Profile – Visibility Sep 10, 2022
Copy link
Contributor

@Mogge Mogge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like it works fine. Sorry for the drastic words, but the code to handle the params in the group resolver is a nightmare that nobody can read. It will be impossible to work on this code as it is in the future.

groupMatchParamsCypher += index === 0 ? ' {' : ''
groupMatchParamsCypher += `${ele[0]}: "${ele[1]}"`
groupMatchParamsCypher += index < matchParamsEntries.length - 1 ? ', ' : '}'
})
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can this be done in some human readable way? Am I right, that we receive an ID, a slug, both or none from the params. So I suggest, if both (ID and slug) are undefined, return empty array or throw an error. We could say, that ID goes over slug if both are present.

Copy link
Member Author

@Tirokk Tirokk Sep 14, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I couldn't find a working solution in Cypher.
What I have found was not working. So I spent a bit more then an hour. @Mogge

I created two hopefully well named and therefore descriptive helper functions instead. Hope that satisfies you …

@Tirokk Tirokk merged commit 017a764 into 5059-epic-groups Sep 15, 2022
@Tirokk Tirokk deleted the 5059-groups/5318-group-profile-second branch September 15, 2022 08:20
@ulfgebhardt ulfgebhardt added this to the 🏃 22/10 Oktober milestone Oct 18, 2022
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.

🚀 [Feature] Implement Group Profile – Next Steps
4 participants