abdera-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jmsn...@apache.org
Subject svn commit: r1203393 - /abdera/abdera2/common/src/main/java/org/apache/abdera2/common/templates/Operation.java
Date Thu, 17 Nov 2011 22:16:56 GMT
Author: jmsnell
Date: Thu Nov 17 22:16:56 2011
New Revision: 1203393

URL: http://svn.apache.org/viewvc?rev=1203393&view=rev
Log:
bug fix in the expansion.. wasn't handling nulls properly

Modified:
    abdera/abdera2/common/src/main/java/org/apache/abdera2/common/templates/Operation.java

Modified: abdera/abdera2/common/src/main/java/org/apache/abdera2/common/templates/Operation.java
URL: http://svn.apache.org/viewvc/abdera/abdera2/common/src/main/java/org/apache/abdera2/common/templates/Operation.java?rev=1203393&r1=1203392&r2=1203393&view=diff
==============================================================================
--- abdera/abdera2/common/src/main/java/org/apache/abdera2/common/templates/Operation.java
(original)
+++ abdera/abdera2/common/src/main/java/org/apache/abdera2/common/templates/Operation.java
Thu Nov 17 22:16:56 2011
@@ -445,7 +445,7 @@ public abstract class Operation implemen
             for (VarSpec varspec : exp) {
               String val = eval(varspec, context, false, "&", ""); // Per Draft Seven
(http://tools.ietf.org/html/draft-gregorio-uritemplate-07)
               if (context.contains(varspec.getName())) {
-                if (!first) buf.append('&');
+                if (!first && val != null) buf.append('&');
                 if ((val != null && !varspec.isExplode()) || varspec.isNoval()) {
                   buf.append(varspec.getName());
                 }



Mime
View raw message