BUGFIX: check method SideBar exists in parent before calling it.

This commit is contained in:
carlos barberis 2012-07-18 10:47:28 +12:00
parent bf287d9e77
commit 8c12345695

View File

@ -109,7 +109,10 @@ class BlogEntry extends Page {
* Get the sidebar from the BlogHolder.
*/
function SideBar() {
return $this->getParent()->SideBar();
if(method_exists($this->Parent(), 'SideBar')) {
return $this->getParent()->SideBar();
}
}
function Content() {