Permalink
Browse files

[CONTINUUM-1721] Preserve the original pom url. Need to find a home f…

…or this code, probably in a utility method closer to where the url-with-credentials is used.

git-svn-id: https://svn.apache.org/repos/asf/continuum/branches/CONTINUUM-1721@697658 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information...
1 parent 6c46702 commit 043a364f4bd6dc3bae3f7752fa271e5eafe63ddc Wendy Smoak committed Sep 22, 2008
@@ -104,33 +104,7 @@ public String execute()
if ( !StringUtils.isEmpty( pomUrl ) )
{
- try
- {
- URL url = new URL( pomUrl );
- if ( pomUrl.startsWith( "http" ) && !StringUtils.isEmpty( scmUsername ) )
- {
- StringBuffer urlBuffer = new StringBuffer();
- urlBuffer.append( url.getProtocol() ).append( "://" );
- urlBuffer.append( scmUsername ).append( ':' ).append( scmPassword ).append( '@' ).append(
- url.getHost() );
- if ( url.getPort() != -1 )
- {
- urlBuffer.append( ":" ).append( url.getPort() );
- }
- urlBuffer.append( url.getPath() );
-
- pom = urlBuffer.toString();
- }
- else
- {
- pom = pomUrl;
- }
- }
- catch ( MalformedURLException e )
- {
- addActionError( "add.project.unknown.error" );
- return doDefault();
- }
+ pom = pomUrl;
}
else
{

0 comments on commit 043a364

Please sign in to comment.