You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lenya.apache.org by an...@apache.org on 2006/08/17 11:45:37 UTC

svn commit: r432193 - /lenya/trunk/src/java/org/apache/lenya/cms/site/simple/SimpleSiteManager.java

Author: andreas
Date: Thu Aug 17 02:45:37 2006
New Revision: 432193

URL: http://svn.apache.org/viewvc?rev=432193&view=rev
Log:
SimpleSiteManager: check if site config file exists

Modified:
    lenya/trunk/src/java/org/apache/lenya/cms/site/simple/SimpleSiteManager.java

Modified: lenya/trunk/src/java/org/apache/lenya/cms/site/simple/SimpleSiteManager.java
URL: http://svn.apache.org/viewvc/lenya/trunk/src/java/org/apache/lenya/cms/site/simple/SimpleSiteManager.java?rev=432193&r1=432192&r2=432193&view=diff
==============================================================================
--- lenya/trunk/src/java/org/apache/lenya/cms/site/simple/SimpleSiteManager.java (original)
+++ lenya/trunk/src/java/org/apache/lenya/cms/site/simple/SimpleSiteManager.java Thu Aug 17 02:45:37 2006
@@ -110,6 +110,11 @@
     protected String getCollectionUuid(Publication pub, String area) {
         String sourceUri = pub.getContentURI(area) + DOCUMENT_PATH;
         try {
+            
+            if (!SourceUtil.exists(sourceUri, manager)) {
+                throw new RuntimeException("The site configuration [" + sourceUri + "] does not exist!");
+            }
+            
             org.w3c.dom.Document xml = SourceUtil.readDOM(sourceUri, manager);
             if (!xml.getDocumentElement().hasAttribute("uuid")) {
                 throw new RuntimeException("The document element of [" + sourceUri



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@lenya.apache.org
For additional commands, e-mail: commits-help@lenya.apache.org