ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Rall <...@apache.org>
Subject [PATCH] Project.java
Date Wed, 12 Jun 2002 23:11:43 GMT
A more concise implementation of getProperty(String).  No functional
change.

Index: Project.java
===================================================================
RCS file: /home/cvspublic/jakarta-ant/src/main/org/apache/tools/ant/Project.java,v
retrieving revision 1.109
diff -u -u -r1.109 Project.java
--- Project.java	1 Jun 2002 12:26:37 -0000	1.109
+++ Project.java	12 Jun 2002 23:09:32 -0000
@@ -495,11 +495,7 @@
      *         or if a <code>null</code> name is provided.
      */
     public String getProperty(String name) {
-        if (name == null) {
-          return null;
-        }
-        String property = (String) properties.get(name);
-        return property;
+        return (name == null ? null : (String) properties.get(name));
     }
 
     /**

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message