Skip to content

Fix filtering when searching for languages in app-hosted mode (BL-15822)#604

Merged
JohnThomson merged 1 commit intomasterfrom
BL15822_FixAppHostedLanguageFiltering
Feb 6, 2026
Merged

Fix filtering when searching for languages in app-hosted mode (BL-15822)#604
JohnThomson merged 1 commit intomasterfrom
BL15822_FixAppHostedLanguageFiltering

Conversation

@andrew-polk
Copy link
Copy Markdown
Contributor

@andrew-polk andrew-polk commented Feb 2, 2026

This change is Reviewable


Open with Devin

Copy link
Copy Markdown

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

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

Devin Review found 1 potential issue.

View issue and 2 additional flags in Devin Review.

Open in Devin Review

Comment thread src/components/appHosted/AppHostedLanguageGroup.tsx Outdated
@andrew-polk andrew-polk force-pushed the BL15822_FixAppHostedLanguageFiltering branch from dd4c6dd to e92c405 Compare February 2, 2026 21:30
@andrew-polk andrew-polk marked this pull request as ready for review February 2, 2026 22:22
Copy link
Copy Markdown
Contributor

@JohnThomson JohnThomson left a comment

Choose a reason for hiding this comment

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

@JohnThomson reviewed 1 file and made 1 comment.
Reviewable status: all files reviewed (commit messages unreviewed), 1 unresolved discussion (waiting on @andrew-polk).


src/components/appHosted/AppHostedLanguageGroup.tsx line 114 at r2 (raw file):

            : matchingLanguages.filter(
                  (lang) => !preferredLangCodes.includes(lang.isoCode)
              );

Not sure how picky to be here. I find that using negations in conditionals that have both branches is usually less clear than using the positive and reversing the then and else. In this case, I think it would be even clearer to have
languagesToDisplay = matchingLanguages.
if (showPreferredLangs) {
// don't show the preferred languages in both places; screen space is precious...
...
But what you have is reasonably clear and will work.

@andrew-polk andrew-polk force-pushed the BL15822_FixAppHostedLanguageFiltering branch from e92c405 to 518cd3a Compare February 6, 2026 19:42
Copy link
Copy Markdown
Contributor Author

@andrew-polk andrew-polk left a comment

Choose a reason for hiding this comment

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

@andrew-polk made 1 comment.
Reviewable status: 0 of 1 files reviewed, 1 unresolved discussion (waiting on @JohnThomson).


src/components/appHosted/AppHostedLanguageGroup.tsx line 114 at r2 (raw file):

Previously, JohnThomson (John Thomson) wrote…

Not sure how picky to be here. I find that using negations in conditionals that have both branches is usually less clear than using the positive and reversing the then and else. In this case, I think it would be even clearer to have
languagesToDisplay = matchingLanguages.
if (showPreferredLangs) {
// don't show the preferred languages in both places; screen space is precious...
...
But what you have is reasonably clear and will work.

I agree that is much better.

Copy link
Copy Markdown

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

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

Devin Review found 1 new potential issue.

View 3 additional findings in Devin Review.

Open in Devin Review

Comment thread src/components/appHosted/AppHostedLanguageGroup.tsx
Copy link
Copy Markdown
Contributor

@JohnThomson JohnThomson left a comment

Choose a reason for hiding this comment

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

@JohnThomson reviewed 1 file and all commit messages, and resolved 1 discussion.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @andrew-polk).

@JohnThomson JohnThomson merged commit 3c9f99f into master Feb 6, 2026
1 check passed
@JohnThomson JohnThomson deleted the BL15822_FixAppHostedLanguageFiltering branch February 6, 2026 21:35
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.

2 participants