maven-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dennis Lundberg <denn...@apache.org>
Subject Re: svn commit: r1050782 - /maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
Date Sun, 19 Dec 2010 15:04:23 GMT
On 2010-12-19 10:52, ltheussl@apache.org wrote:
> Author: ltheussl
> Date: Sun Dec 19 09:52:24 2010
> New Revision: 1050782
> 
> URL: http://svn.apache.org/viewvc?rev=1050782&view=rev
> Log:
> remove pointless if
> 
> Modified:
>     maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
> 
> Modified: maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
> URL: http://svn.apache.org/viewvc/maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java?rev=1050782&r1=1050781&r2=1050782&view=diff
> ==============================================================================
> --- maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
(original)
> +++ maven/shared/trunk/maven-doxia-tools/src/main/java/org/apache/maven/doxia/tools/DefaultSiteTool.java
Sun Dec 19 09:52:24 2010
> @@ -1312,15 +1312,12 @@ public class DefaultSiteTool
>       */
>      private void populateModulesMenuItemsFromModels( MavenProject project, List<Model>
models, Menu menu )
>      {
> -        if ( models != null && models.size() > 1 )

I'm not sure why it does what it does, but when you remove the above
line you alter the behavior. Note the "models.size() > 1" part - it is
not "models.size() > 0".

> +        for ( Model model : models )
>          {
> -            for ( Model model : models )
> -            {
> -                String reactorUrl = model.getUrl();
> -                String name = model.getName();
> +            String reactorUrl = model.getUrl();
> +            String name = model.getName();
>  
> -                appendMenuItem( project, menu, name, reactorUrl, model.getArtifactId()
);
> -            }
> +            appendMenuItem( project, menu, name, reactorUrl, model.getArtifactId() );
>          }
>      }
>  
> 
> 
> 


-- 
Dennis Lundberg

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Mime
View raw message