Author: bentmann
Date: Tue Feb 17 21:21:35 2009
New Revision: 745259

URL: http://svn.apache.org/viewvc?rev=745259&view=rev
Log:
[MNG-3732] [regression] project.getActiveProfiles() has not the same behaviour

Modified:
    
maven/components/trunk/maven-project/src/main/java/org/apache/maven/profiles/build/DefaultProfileAdvisor.java

Modified: 
maven/components/trunk/maven-project/src/main/java/org/apache/maven/profiles/build/DefaultProfileAdvisor.java
URL: 
http://svn.apache.org/viewvc/maven/components/trunk/maven-project/src/main/java/org/apache/maven/profiles/build/DefaultProfileAdvisor.java?rev=745259&r1=745258&r2=745259&view=diff
==============================================================================
--- 
maven/components/trunk/maven-project/src/main/java/org/apache/maven/profiles/build/DefaultProfileAdvisor.java
 (original)
+++ 
maven/components/trunk/maven-project/src/main/java/org/apache/maven/profiles/build/DefaultProfileAdvisor.java
 Tue Feb 17 21:21:35 2009
@@ -229,12 +229,15 @@
 
                 if ( root != null )
                 {
-                    List active = root.getActiveProfiles();
+                    List<String> active = root.getActiveProfiles();
 
                     if ( ( active != null ) && !active.isEmpty() )
                     {
                         ProfileActivationContext ctx = 
profileManager.getProfileActivationContext();
-                        ctx.setExplicitlyActiveProfileIds( 
root.getActiveProfiles() );
+                        for ( String profileId : active )
+                        {
+                            ctx.setActive( profileId );
+                        }
                     }
 
                     for ( Iterator it = root.getProfiles().iterator(); 
it.hasNext(); )


Reply via email to