formatting only

git-svn-id: https://svn.apache.org/repos/asf/archiva/branches/MRM-1025@885816 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Brett Porter 2009-12-01 16:17:08 +00:00
parent 52bcd1b58b
commit cfabf95ff6
1 changed files with 21 additions and 20 deletions

View File

@ -292,8 +292,7 @@ public class UploadAction
try
{
Configuration config = configuration.getConfiguration();
ManagedRepositoryConfiguration repoConfig =
config.findManagedRepositoryById( repositoryId );
ManagedRepositoryConfiguration repoConfig = config.findManagedRepositoryById( repositoryId );
ArtifactReference artifactReference = new ArtifactReference();
artifactReference.setArtifactId( artifactId );
@ -345,14 +344,16 @@ public class UploadAction
filename = filename.replaceAll( "SNAPSHOT", timestamp + "-" + newBuildNumber );
}
boolean fixChecksums = !( config.getRepositoryScanning().getKnownContentConsumers().contains( "create-missing-checksums" ) );
boolean fixChecksums =
!( config.getRepositoryScanning().getKnownContentConsumers().contains( "create-missing-checksums" ) );
try
{
File targetFile = new File( targetPath, filename );
if( targetFile.exists() && !VersionUtil.isSnapshot( version ) && repoConfig.isBlockRedeployments() )
if ( targetFile.exists() && !VersionUtil.isSnapshot( version ) && repoConfig.isBlockRedeployments() )
{
addActionError( "Overwriting released artifacts in repository '" + repoConfig.getId() + "' is not allowed." );
addActionError(
"Overwriting released artifacts in repository '" + repoConfig.getId() + "' is not allowed." );
return ERROR;
}
else
@ -379,7 +380,7 @@ public class UploadAction
try
{
File generatedPomFile = createPom( targetPath, pomFilename );
if( fixChecksums )
if ( fixChecksums )
{
fixChecksums( generatedPomFile );
}
@ -413,7 +414,7 @@ public class UploadAction
}
// explicitly update only if metadata-updater consumer is not enabled!
if( !config.getRepositoryScanning().getKnownContentConsumers().contains( "metadata-updater" ) )
if ( !config.getRepositoryScanning().getKnownContentConsumers().contains( "metadata-updater" ) )
{
updateMetadata( metadata, metadataFile, lastUpdatedTimestamp, timestamp, newBuildNumber, fixChecksums );
}
@ -467,7 +468,7 @@ public class UploadAction
input.close();
}
if( fixChecksums )
if ( fixChecksums )
{
fixChecksums( new File( targetPath, targetFilename ) );
}
@ -564,7 +565,7 @@ public class UploadAction
RepositoryMetadataWriter.write( metadata, metadataFile );
if( fixChecksums )
if ( fixChecksums )
{
fixChecksums( metadataFile );
}