Update of 
/var/cvs/contributions/CMSContainer/cmsc/taglib/src/java/com/finalist/cmsc/taglib/portlet
In directory 
james.mmbase.org:/tmp/cvs-serv25213/cmsc/taglib/src/java/com/finalist/cmsc/taglib/portlet

Modified Files:
        BasicURLTag.java 
Log Message:
CMSC-1193 - Tag cmsc:renderURL does not take account of the host location of 
the page: improvement to Java code for better page input.


See also: 
http://cvs.mmbase.org/viewcvs/contributions/CMSContainer/cmsc/taglib/src/java/com/finalist/cmsc/taglib/portlet
See also: http://www.mmbase.org/jira/browse/CMSC-1193


Index: BasicURLTag.java
===================================================================
RCS file: 
/var/cvs/contributions/CMSContainer/cmsc/taglib/src/java/com/finalist/cmsc/taglib/portlet/BasicURLTag.java,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -b -r1.13 -r1.14
--- BasicURLTag.java    20 Jan 2009 15:22:34 -0000      1.13
+++ BasicURLTag.java    20 Jan 2009 15:56:18 -0000      1.14
@@ -164,8 +164,8 @@
          link = SiteManagement.getPath(item, !ServerUtil.useServerName());
       }
       else {
-         link = page;
-         //Throw error in from CMSC 1.6: illegal argument exception, should 
use this with full path
+         //Throw error, should use this function with full path!
+         throw new IllegalArgumentException("item == null; getLink should be 
called with full page path!");
       }
 
       return link;
@@ -176,10 +176,8 @@
       String host = null;
       if (ServerUtil.useServerName()) {
          NavigationItem item = SiteManagement.convertToNavigationItem(page);
-         if (item != null) {
             host = SiteManagement.getSite(item);
          }
-      }
       return host;
    }
 
_______________________________________________
Cvs mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/cvs

Reply via email to