Error

Call to a member function getTodayOpenDate() on null

/var/www/pizzagoOnline/protected/modules/pizzago/views/pizzagoOrder/index.php(114)

102               <div class="restaurantBackground">
103                   <div class="overlay">
104                       <?php
105                         if ($restaurant->logo != null && !preg_match("/^\s*$/", $restaurant->logo)) {
106                       ?>
107                       <img src="<?php echo $restaurant->logo; ?>">
108                       <?php } else { ?>
109                       <img src="<?php echo $this->module->getAssetsUrl(); ?>/images/logo.png">
110                       <?php } ?>
111                       <h1><?php echo $restaurant->name; ?></h1>
112                       <p class="location-address"><?php echo $location->address; ?></p>
113                       <?php
114                         if ($location->getTodayOpenDate() !== null) {
115                       ?>
116                       <p class="location-hours">Open Today: <?php echo $this->getLocationTodayOpenTime(); ?> - <?php echo $this->getLocationTodayCloseTime(); ?></p>  
117                       <?php
118                         }
119                         else {
120                       ?>
121                       <p class="location-hours">Closed Today</p> 
122                       <?php
123                         }  
124                       ?>
125                       <!--Legend-->
126                       <img src="<?php echo $this->module->getAssetsUrl(); ?>/images/spicy_icon.png" height="20px" alt="SpicyIcon" class="legend"/> : Spicy &emsp;

Stack Trace

#4
+
 /var/www/pizzagoOnline/protected/modules/pizzago/controllers/PizzagoOrderController.php(1433): CController->render()
1428         }
1429         else {
1430             $this->render($url ,array(
1431                 'restaurant'=>$this->_restaurant,
1432                 'location'=>$this->_location,
1433                 'frame'=>$frame
1434             ));
1435         }
1436     }
1437 
1438     public function actionFacebookIndex()
#8
+
 /var/www/pizzagoOnline/protected/modules/pizzago/controllers/PizzagoOrderController.php(6064): CFilterChain->run()
6059                 }
6060             }
6061         }
6062 
6063         //complete the running of other filters and execute the requested action
6064         $filterChain->run();
6065     }
6066     
6067     /**
6068     * Protected method to load the associated Websites model class
6069     * @param integer websiteId the primary identifier of the associated Website
#11
+
 /var/www/pizzagoOnline/protected/modules/pizzago/controllers/PizzagoOrderController.php(4835): CFilterChain->run()
4830         }
4831         else
4832             throw new CHttpException(403,'Must specify a restaurant before performing this action.');
4833 
4834         //complete the running of other filters and execute the requested action
4835         $filterChain->run();
4836     }
4837 
4838     public function actionApiGetDispatchOrders()
4839     {
4840         if ($_SERVER['REQUEST_METHOD'] == 'POST' && empty($_POST))
2024-03-28 23:21:15 Apache/2.4.41 (Ubuntu) Yii Framework/1.1.14