Index: src/main/java/info/magnolia/cms/taglibs/BaseContentTag.java
===================================================================
--- src/main/java/info/magnolia/cms/taglibs/BaseContentTag.java (revision 22807)
+++ src/main/java/info/magnolia/cms/taglibs/BaseContentTag.java (working copy)
@@ -36,8 +36,10 @@
import info.magnolia.cms.beans.config.ContentRepository;
import info.magnolia.cms.core.Content;
import info.magnolia.cms.core.NodeData;
+import info.magnolia.cms.i18n.I18nContentSupportFactory;
import info.magnolia.cms.util.ContentUtil;
+import javax.jcr.PathNotFoundException;
import javax.jcr.RepositoryException;
import javax.servlet.jsp.tagext.TagSupport;
@@ -159,17 +161,19 @@
if (StringUtils.isNotEmpty(this.nodeDataName)) {
Content currentPage = getCurrentPage();
- NodeData nodeData = contentNode.getNodeData(this.nodeDataName);
-
+ NodeData nodeData = I18nContentSupportFactory.getI18nSupport().getNodeData(contentNode, this.nodeDataName);
try {
while (inherit && currentPage.getLevel() > 0 && !nodeData.isExist()) {
- currentPage = currentPage.getParent();
+ System.out.println("here you are: " + currentPage.getLevel());
+ currentPage = currentPage.getParent();
contentNode = resolveNode(currentPage);
- nodeData = contentNode.getNodeData(this.nodeDataName);
+ if (contentNode != null) {
+ nodeData = I18nContentSupportFactory.getI18nSupport().getNodeData(contentNode, this.nodeDataName);
+ }
}
}
catch (RepositoryException e) {
- log.error(e.getMessage(), e);
+ log.error(e.getMessage(), e);
}
}
@@ -194,6 +198,9 @@
// e.g.
// e.g.
return currentPage.getContent(contentNodeCollectionName).getContent(contentNodeName);
+
+
+
}
else {
if (currentParagraph == null) {
@@ -232,8 +239,13 @@
}
}
}
+ catch (PathNotFoundException pe) {
+ if (log.isDebugEnabled()) {
+ log.debug(pe.getMessage());
+ }
+ }
catch (RepositoryException re) {
- if (log.isDebugEnabled()) {
+ if (log.isDebugEnabled()) {
log.debug(re.getMessage());
}
}