Closed (fixed)
Project:
Feeds
Version:
8.x-3.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
30 Mar 2020 at 07:53 UTC
Updated:
19 May 2020 at 08:54 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
megachrizI noticed this too in the Dutch language. It always puts an 's' after the name of a content type, where using 'en' would make more sense in Dutch.
For example, I sometimes see this message:
(meaning: updated 4 components)
While the correct Dutch phrase in this case would be:
I didn't see a way yet how to fix that. Content types don't have plural labels, just one label.
You say it happens for entity type names as well?
Comment #3
mikran commentedBundles do not yet support plural labels: #2765065: Allow plurals on bundle labels
This patch adds translatable plurals for entity types and uses singular form for bundle for now. IMO it is better to use translatable singular form instead of malformed plural.
Comment #4
mikran commentedYes it does. I'm not sure why there is @item and @entity when both appear to be entities. It is really hard to translate this properly even with translated plural forms.
Comment #6
megachrizIt would be cool if we could fix this issue in a way that it still looks nice in English, for example "Created 6 articles" instead of "Created 6 Article".
Because in Drupal 9, Drupal core no longer has a dependency on doctrine/inflector. So if we keep using the inflector, then Feeds will be harder to install for non-composer users in Drupal 9. See also #3129114: Fix Drupal 9 test failures.
Comment #7
megachrizI see the following interesting piece in the patch from #2765065-101: Allow plurals on bundle labels:
For the content type 'Article' without specific singular and plural labels this would result into:
This seems like a nice workaround. I see that in #2765065: Allow plurals on bundle labels, the label is also converted to lowercase. However, that would at least be incorrect for the German language (as also noted on that issue). But even in other languages you can't be sure whether it's correct to convert the label to lowercase. For example, on one site I have a content type called 'FAQ' - an abbreviation - and in that case I think it's better to keep it capitalized. In that case the messages in Feeds would become:
The patch makes the plural bundle label "@label items" and hopefully updates all related tests.
Comment #8
megachrizI ran the tests against D9 to check if there are no more mentions of
Doctrine\Common\Inflector\Inflectorin the code base. And this appears the case!@mikran
What do you think of the patch in #7?
Comment #9
mikran commentedLooks good to me.
Comment #11
megachrizThanks for taking a look, @mikran
Committed #7.