]> source.dussan.org Git - archiva.git/commitdiff
fix pom snippet generation
authorOlivier Lamy <olamy@apache.org>
Sun, 11 Sep 2011 22:26:12 +0000 (22:26 +0000)
committerOlivier Lamy <olamy@apache.org>
Sun, 11 Sep 2011 22:26:12 +0000 (22:26 +0000)
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1169552 13f79535-47bb-0310-9956-ffa450edef68

archiva-modules/archiva-web/archiva-webapp/src/main/java/org/apache/archiva/web/tags/CopyPasteSnippetTag.java

index c031b091a866acf06e205d34f29a61f952709cd4..b239d4989219269171777acf4b0850e9504dbd08 100644 (file)
@@ -26,6 +26,7 @@ import javax.servlet.jsp.JspWriter;
 import javax.servlet.jsp.PageContext;
 import javax.servlet.jsp.tagext.TagSupport;
 
+import org.apache.archiva.admin.repository.managed.ManagedRepository;
 import org.apache.commons.lang.StringEscapeUtils;
 import org.apache.maven.archiva.configuration.ManagedRepositoryConfiguration;
 import org.apache.archiva.web.util.ContextUtils;
@@ -70,9 +71,9 @@ public class CopyPasteSnippetTag
             buf.append( "Error generating snippet." );
             log.error( "Unable to generate snippet for null object." );
         }
-        else if ( object instanceof ManagedRepositoryConfiguration )
+        else if ( object instanceof ManagedRepository )
         {
-            ManagedRepositoryConfiguration repo = (ManagedRepositoryConfiguration) object;
+            ManagedRepository repo = (ManagedRepository) object;
             
             if ( TOGGLE.equals( wrapper ) )
             {
@@ -122,7 +123,7 @@ public class CopyPasteSnippetTag
         this.wrapper = wrapper;
     }
 
-    private void createSnippet( StringBuilder snippet, ManagedRepositoryConfiguration repo, PageContext pageContext )
+    private void createSnippet( StringBuilder snippet, ManagedRepository repo, PageContext pageContext )
     {
         snippet.append( "<project>\n" );
         snippet.append( "  ...\n" );