Lucas_Werkmeister_WMDE added a comment.

  Should be relatively easy to change – pass the user language from  
`ViolationMessageRendererFactory::getViolationMessageRenderer()` into 
`ViolationMessageRenderer`, then adjust 
`ViolationMessageRenderer::renderLanguage()` to pass the user language code 
into `Language::fetchLanguageName()`. Violation messages are rendered per 
request – the cache contains the unrendered, serialized message – so there 
should be no issues about wrong language names being shown to other users due 
to bad caching.
  
  It would be nice, but not required, to also refactor the code at this time, 
to inject a `LanguageNameUtils` service instance into 
`ViolationMessageRenderer` and its factory, instead of using the deprecated 
`Language::fetchLanguageName()` method.
  
  This could potentially be a #good_first_task 
<https://phabricator.wikimedia.org/tag/good_first_task/>, but needs a product 
decision first IMHO, on whether we want to make this change or not.

TASK DETAIL
  https://phabricator.wikimedia.org/T316936

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Lucas_Werkmeister_WMDE
Cc: Lucas_Werkmeister_WMDE, Aklapper, Agabi10, Astuthiodit_1, karapayneWMDE, 
Invadibot, maantietaja, ItamarWMDE, Akuckartz, Eihel, Nandana, Lahi, Gq86, 
GoranSMilovanovic, QZanden, Esc3300, LawExplorer, _jensen, rosalieper, 
Scott_WUaS, abian, Wikidata-bugs, aude, Mbch331
_______________________________________________
Wikidata-bugs mailing list -- wikidata-bugs@lists.wikimedia.org
To unsubscribe send an email to wikidata-bugs-le...@lists.wikimedia.org

Reply via email to