Overridden translation sticking after being pluralized

Hello :wave:

This happened with me recently with js.badges.awarded string. My site is in Hungarian language.

When the js.badges.awarded was implemented I translated it on /admin/customize/site_texts and when the pluralized version is overrided it the not pluralized version js.badges.awarded was stucked and was not findable on /admin/customize/site_texts.
Because the available strings on /admin/customize/site_texts was only the js.badges.awarded.one and js.badges.awarded.other

I am not sure why it’s happened but maybe because the js.badges.awarded was not contains interpolation keys and the new pluralized one contains the %{number}. :thinking:

So it seems if the text is overridden then the updated version will not replace this and the previously overridden text will keep.

I removed this in rails.

TranslationOverride.where(translation_key: "js.badges.awarded").delete_all

By the way it’s usually works like if a string is translated and then the pluralized version comes then on Hungarian language it use the other format.

I am not sure it’s a bug? And that it happens with the pluralized version it’s maybe can happen without pluralized change. :thinking:

Thank you :slightly_smiling_face:

3 Likes

I think there’s been a bit of work on plurals recently that may have resolved this. Can you still repro?

2 Likes

Nope, but this is not something I can repro without those kind of changes but I think this issue is probably related with: Issue with pluralized (count) translation override I think maybe that was the issue I couldn’t able to edit the plurals correctly. Now it works! :slightly_smiling_face:

3 Likes

Awesome. :slight_smile: I’ll close this off for now as that sounds promising, but let us know if you hit it again and I’ll reopen it. :+1:

3 Likes