2006/unicorn/src/org/w3c/unicorn/util Language.java,1.7,1.8

Update of /sources/public/2006/unicorn/src/org/w3c/unicorn/util
In directory hutz:/tmp/cvs-serv31918/src/org/w3c/unicorn/util

Modified Files:
	Language.java 
Log Message:
removed potential NPE

Index: Language.java
===================================================================
RCS file: /sources/public/2006/unicorn/src/org/w3c/unicorn/util/Language.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -d -r1.7 -r1.8
--- Language.java	6 Oct 2009 08:16:02 -0000	1.7
+++ Language.java	6 Oct 2009 10:02:46 -0000	1.8
@@ -103,6 +103,8 @@
 		String message = Framework.getLanguageProperties().get(lang).getProperty(messageKey.replace("$", ""));
 		String result = message;
 		int i = 1;
+		if (args == null)
+			return result;
 		for (String str : args) {
 			result = result.replaceAll("%"+i, str);
 			i++;

Received on Tuesday, 6 October 2009 10:02:50 UTC