mirror of https://github.com/apache/archiva.git
Eliminating duplicate repositories from showing up after the conversion.
git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/trunk@583630 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
e799f29dc2
commit
54207afb87
|
@ -88,7 +88,7 @@ public class DefaultArchivaConfiguration
|
|||
* Configuration Listeners we've registered.
|
||||
*/
|
||||
private Set<ConfigurationListener> listeners = new HashSet<ConfigurationListener>();
|
||||
|
||||
|
||||
/**
|
||||
* Registry Listeners we've registered.
|
||||
*/
|
||||
|
@ -153,6 +153,9 @@ public class DefaultArchivaConfiguration
|
|||
config.addRemoteRepository( repo );
|
||||
}
|
||||
}
|
||||
|
||||
// Prevent duplicate repositories from showing up.
|
||||
config.getRepositories().clear();
|
||||
}
|
||||
|
||||
// Normalize the order fields in the proxy connectors.
|
||||
|
@ -255,7 +258,7 @@ public class DefaultArchivaConfiguration
|
|||
|
||||
new ConfigurationRegistryWriter().write( configuration, section );
|
||||
section.save();
|
||||
|
||||
|
||||
triggerEvent( ConfigurationEvent.SAVED );
|
||||
|
||||
this.configuration = processExpressions( configuration );
|
||||
|
@ -278,8 +281,8 @@ public class DefaultArchivaConfiguration
|
|||
try
|
||||
{
|
||||
( (Initializable) registry ).initialize();
|
||||
|
||||
for ( RegistryListener regListener: registryListeners )
|
||||
|
||||
for ( RegistryListener regListener : registryListeners )
|
||||
{
|
||||
addRegistryChangeListener( regListener );
|
||||
}
|
||||
|
@ -288,7 +291,7 @@ public class DefaultArchivaConfiguration
|
|||
{
|
||||
throw new RegistryException( "Unable to reinitialize configuration: " + e.getMessage(), e );
|
||||
}
|
||||
|
||||
|
||||
triggerEvent( ConfigurationEvent.SAVED );
|
||||
|
||||
return registry.getSection( KEY + ".user" );
|
||||
|
@ -329,7 +332,7 @@ public class DefaultArchivaConfiguration
|
|||
|
||||
listeners.remove( listener );
|
||||
}
|
||||
|
||||
|
||||
public void addChangeListener( RegistryListener listener )
|
||||
{
|
||||
addRegistryChangeListener( listener );
|
||||
|
@ -352,7 +355,6 @@ public class DefaultArchivaConfiguration
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
public void initialize()
|
||||
throws InitializationException
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue