From: <fa...@vh...> - 2005-09-12 15:04:42
|
Author: fabrice Date: 2005-09-12 16:55:36 +0200 (Mon, 12 Sep 2005) New Revision: 776 Modified: ccm-cms/trunk/src/com/arsdigita/cms/CMSContext.java Log: Removing notnull constraint for content lists Modified: ccm-cms/trunk/src/com/arsdigita/cms/CMSContext.java =================================================================== --- ccm-cms/trunk/src/com/arsdigita/cms/CMSContext.java 2005-09-12 14:55:15 UTC (rev 775) +++ ccm-cms/trunk/src/com/arsdigita/cms/CMSContext.java 2005-09-12 14:55:36 UTC (rev 776) @@ -85,11 +85,12 @@ /** * Gets the current content section - * @pre hasContentSection() == true + * not anymore: hasContentSection() == true * @return the currently selected content section */ public final ContentSection getContentSection() { - Assert.assertNotNull(m_section, "section"); + // removing this which is not true when viewing category pages + //Assert.assertNotNull(m_section, "section"); return m_section; } @@ -119,7 +120,11 @@ * @return the current content item */ public final ContentItem getContentItem() { - Assert.assertNotNull(m_item, "item"); + // removing this which is necessarily true in ContentList + //Assert.assertNotNull(m_item, "item"); + if (s_log.isDebugEnabled() && m_item == null) { + s_log.debug("Content item is null"); + } return m_item; } |