ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jlboud...@apache.org
Subject svn commit: r1504796 - /ant/easyant/core/trunk/src/main/java/org/apache/easyant/core/report/XMLEasyAntReportWriter.java
Date Fri, 19 Jul 2013 07:13:35 GMT
Author: jlboudart
Date: Fri Jul 19 07:13:35 2013
New Revision: 1504796

URL: http://svn.apache.org/r1504796
Log:
Import type shouldn't be null on reports

Modified:
    ant/easyant/core/trunk/src/main/java/org/apache/easyant/core/report/XMLEasyAntReportWriter.java

Modified: ant/easyant/core/trunk/src/main/java/org/apache/easyant/core/report/XMLEasyAntReportWriter.java
URL: http://svn.apache.org/viewvc/ant/easyant/core/trunk/src/main/java/org/apache/easyant/core/report/XMLEasyAntReportWriter.java?rev=1504796&r1=1504795&r2=1504796&view=diff
==============================================================================
--- ant/easyant/core/trunk/src/main/java/org/apache/easyant/core/report/XMLEasyAntReportWriter.java
(original)
+++ ant/easyant/core/trunk/src/main/java/org/apache/easyant/core/report/XMLEasyAntReportWriter.java
Fri Jul 19 07:13:35 2013
@@ -428,20 +428,19 @@ public class XMLEasyAntReportWriter {
         }
 
         for (ImportedModuleReport importedModuleReport : importedModuleReports) {
+            String mode = importedModuleReport.getMode() != null ? importedModuleReport.getMode()
: "import";
             StringBuffer importedModule = new StringBuffer();
             try {
                 ModuleRevisionId mrid = ModuleRevisionId.parse(importedModuleReport.getModuleMrid());
                 importedModule.append("\t\t\t<import organisation=\"").append(mrid.getOrganisation())
                         .append("\" name=\"").append(mrid.getName()).append("\" revision=\"")
-                        .append(mrid.getRevision()).append("\" type=\"").append(importedModuleReport.getMode())
-                        .append("\"");
+                        .append(mrid.getRevision()).append("\" type=\"").append(mode).append("\"");
 
             } catch (IllegalArgumentException e) {
                 Message.debug("Unable to parse " + importedModuleReport.getModuleMrid());
                 importedModule.append("                        <import organisation=\"")
                         .append(importedModuleReport.getModuleMrid()).append("\" name=\"").append("null")
-                        .append("\" revision=\"").append("null").append("\" type=\"")
-                        .append(importedModuleReport.getMode()).append("\"");
+                        .append("\" revision=\"").append("null").append("\" type=\"").append(mode).append("\"");
 
             }
             importedModule.append(" mandatory=\"");



Mime
View raw message