Details
-
Bug
-
Status: Closed
-
Resolution: Fixed
-
7.0.X, 7.1.X, Master
-
7.1.x, 7.0.x
-
Committed
-
0.25
-
3
-
Localization
Description
Description
The order of the parameters called is not correct within the configuration values from the method:
LocalizationUtil.getLocalizationXmlFromPreferences
On 6.2, this method would return the value passed in the parameter defaultValue if the portlet preferences were empty. In 7.0, 7.1, and master, the method now gives back the string "null", leading to incorrect text being displayed (see screenshot).
Steps to Reproduce
1) Navigate to Control Panel > Configuration > Server Administration
2) Click Script, and enter the following groovy script into the console:
defaultValue = com.liferay.portal.kernel.util.LocalizationUtil.getLocalizationXmlFromPreferences(preferences, actionRequest, "test", "testvalue"); out.println(defaultValue);
Results of Testing
Expected Behavior: Script returns the value "testValue"
Actual Behavior: Script returns "null." Order of parameters is not correct, as defaultValue is passed into the wrong parameter.
Master
Reproduced.
77c92453dc0c04de0013e1ca1e996fdd358d686f
Branch
Reproduced.
487ddea1c24b1e464975e869387094b999215ec5