Unhandled Error!

Trying to get property of non-object

Document Product category page.
Document type CMS page
Line 11
Exception class Cms_ExecutionException

Code Highlight

	$category_url_param = $this->request_param(-1);
	if(is_numeric($category_url_param)){
		$category_url_param = $this->request_param(-2);
		$extension = $this->request_param(-1);
	}
	$category = Shop_Category::create()->find_by_url_name($category_url_param);
	if($category->parent){
		$category_base_url = 'category/'.$category->parent->url_name;
	}else{
		$category_base_url = 'category';
	}
 
 
# Document Type
1 Product category page. CMS page