Fixing MNG-2861.

git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@646142 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
John Dennis Casey 2008-04-08 23:49:47 +00:00
parent 5691b96e4d
commit 21d8a411f6
1 changed files with 10 additions and 0 deletions

View File

@ -207,6 +207,16 @@ public class MavenMetadataSource
return null;
}
//MNG-2861: the artifact data has changed. If the available versions where previously retrieved,
//we need to update it. TODO: shouldn't the versions be merged across relocations?
List available = artifact.getAvailableVersions();
if ( available != null && !available.isEmpty() )
{
artifact.setAvailableVersions( retrieveAvailableVersions( artifact, localRepository,
remoteRepositories ) );
}
String message = "\n This artifact has been relocated to " + artifact.getGroupId() + ":" +
artifact.getArtifactId() + ":" + artifact.getVersion() + ".\n";