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

“Mute words & tags” menu allows you to add a word to your muted words list multiple times #7472

Open
cpeterso opened this issue Jan 17, 2025 · 1 comment · May be fixed by #7481
Open
Labels
bug Something isn't working

Comments

@cpeterso
Copy link

Steps to Reproduce

  1. Open a post in the iOS app or the web app.
  2. Open the … menu and select “Mute words & tags”.
  3. Enter a word to mute, such as “test”, and “Add +” it.
  4. Repeat step 3, entering the same word multiple times.
  5. You will see the word listed multiple times in “Your muted words” list. See the attached screenshot.

This issue is more of a problem when muting a word that you forgot you already muted earlier because the two muted words won’t appear next to each other in the list. If you later remove one of those entries, you won’t know to remove the other entry. Then you will be confused why the word is still muted even though you removed it from the list.

Instead of showing an error message to prevent muting of an already-muted word, I recommend silently moving the old muted word to the top of the list, pretending the word was entered successfully. The user didn’t need to know the truth because they got the result they wanted: their word was added to the top of the muted word list. 👍

Attachments

Image

What platform(s) does this occur on?

iOS

Device Info

iPhone 15 Plus running iOS 18.2.1

What version of the app are you using?

Build version: 1.96.4.818; Bundle info: 615bbc3 (prod); Bundle date: 25010300; Platform: ios; Platform version: 18.2.1

Additional Information

No response

@cpeterso cpeterso added the bug Something isn't working label Jan 17, 2025
gabcvit added a commit to gabcvit/social-app that referenced this issue Jan 18, 2025
- Added a check to find duplicated muted words before adding them
- If muted word is found in `moderationPrefs`. It will show an error
- Added a new string for translating
@gabcvit gabcvit linked a pull request Jan 18, 2025 that will close this issue
@gabcvit
Copy link

gabcvit commented Jan 18, 2025

Hey @cpeterso , thanks for the issue! I had a look at it and proposed a PR to the maintainers.
In short, I have added a check that should stop a duplicated muted word from being added.

I had some issues implementing your recommended solution though

  1. The way this component is currently implemented doesn't allow modification of the data being rendered, as it's closely coupled with the content we get from the API, and shown at the same order we get from there.
  2. If I were to decouple the data in order to render it, such an approach would also add an UX inconsistency in case the user decides for instance to add a duplicated word, navigate out of the screen and then back, the word would be pushed to the its' previous position again.

Instead, I went with an error message. It's a simpler and yet more transparent approach. I hope that would be ok for you 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants