You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@velocity.apache.org by bu...@apache.org on 2004/02/03 06:48:56 UTC
DO NOT REPLY [Bug 26623] New: -
Custom format in NumberTool doesn't use the provided Locale
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=26623>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND
INSERTED IN THE BUG DATABASE.
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=26623
Custom format in NumberTool doesn't use the provided Locale
Summary: Custom format in NumberTool doesn't use the provided
Locale
Product: Velocity
Version: 1.4
Platform: All
OS/Version: All
Status: NEW
Severity: Normal
Priority: Other
Component: Tools
AssignedTo: velocity-dev@jakarta.apache.org
ReportedBy: lari.hotari@sagire.fi
There is a small bug in NumberTool, it doesn't use the provided Locale when
using a custom format.
patch:
Index: NumberTool.java
===================================================================
RCS file:
/home/cvspublic/jakarta-velocity-tools/src/java/org/apache/velocity/tools/generic/NumberTool.java,v
retrieving revision 1.1
diff -u -r1.1 NumberTool.java
--- NumberTool.java 6 Dec 2003 05:44:37 -0000 1.1
+++ NumberTool.java 3 Feb 2004 05:44:32 -0000
@@ -223,7 +223,7 @@
if (style < 0)
{
// we have a custom format
- nf = new DecimalFormat(format, new DecimalFormatSymbols(getLocale()));
+ nf = new DecimalFormat(format, new DecimalFormatSymbols(locale));
}
else
{
---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-dev-help@jakarta.apache.org