Unhandled Error!

Trying to get property of non-object

Document Category
Document type CMS page
Line 5
Exception class Cms_ExecutionException

Code Highlight

<? if(BODY_CLASS == 'sungold') : ?>
            <ul class="breadcrumb grid_12">
                <li class="prev"><a href="/">Home</a></li>
                <li class="prev"><a href="/shop">Shopping</a></li>
<? if($category->parent && $category->parent->code != 'sungold') : ?>
                <li class="prev"><a href="<?= $category->parent->page_url('/category') ?>"><?= h($category->parent->name) ?></a></li>
<? endif ?>
                <li class="current"><a href="<?= $category->page_url('/category') ?>"><?= h($category->name) ?></a></li>
            </ul>
<? elseif(BODY_CLASS == 'diamonds' || BODY_CLASS == "dwu" || BODY_CLASS == "kernel" || BODY_CLASS == "mcs" || BODY_CLASS == "trailking") :
 
    switch(BODY_CLASS)
    {
# Document Type
1 Category CMS page