This issue has been created
 
 
XWiki Commons / cid:jira-generated-image-avatar-4cf6d625-36c1-4b3c-adc6-fc690c5d4591 XCOMMONS-3067 Open

Provide a Spoon check to not rely on Locale(String) constructor

 
View issue   ยท   Add comment
 

Issue created

 
cid:jira-generated-image-avatar-6b38b59a-9f88-4f2a-9a8e-63d55a2c02ab Simon Urli created this issue on 20/Jun/24 15:25
 
Summary: Provide a Spoon check to not rely on Locale(String) constructor
Issue Type: cid:jira-generated-image-avatar-4cf6d625-36c1-4b3c-adc6-fc690c5d4591 Improvement
Affects Versions: 15.10.10
Assignee: Unassigned
Components: Development Issues only
Created: 20/Jun/24 15:25
Priority: cid:jira-generated-image-static-major-0c6ec5c1-5678-4708-b7d0-e62af1454254 Major
Reporter: Simon Urli
Description:

We should never rely on the Locale(String) constructor since we always want to be able to deal with country code and this constructor is only for language code. So we should have a way to detect those calls and discard them.
Instead we should use LocaleUtils#toLocale.
See also XWIKI-20651