Placeholder mismatch in plural forms

In the "Settings" app, the language plural rule system is used erroneously in the following string:

  • One: <xliff:g id="app">%1$s</xliff:g> behaving abnormally
  • Other: <xliff:g id="number">%2$d</xliff:g> apps behaving abnormally

In my language, the same plural form is used for the numbers 1 and 11, resulting in undefined behavior. It might even crash, depending on how resilient the string formatter is if one tries to replace a string placeholder with a number.

Expected Behavior

The same variable is used in all plural forms for the same string

Current Behavior

1 (and in my language also 11) has a placeholder for an app name, other numbers have a placeholder for the number of apps

Possible Solution

Fix the string markup by introducing a separate string for the case of 1 if you want to keep the special case for the app name. Otherwise, use the number.

Steps to Reproduce

  1. https://crowdin.com/translate/lineageos-aosp/all/en-gd?filter=basic&value=0#q=behaving%20normally

ETA: Same problem with

  • One: <xliff:g id="app">%1$s</xliff:g> draining battery
  • Other: Apps draining battery

No device info, I'm just translating at this point.

/device all
/version all starring from lineage-15.1
/date N/A
/kernel N/A
/baseband N/A
/mods N/A

I have read the directions.

Edited Jul 09, 2021 by GunChleoc
Assignee Loading
Time tracking Loading