Skip to content
THIS IS DEV LEVEL 8
Oriental Express - Austin

This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.
Your order
Whoops! There was an error.
RedisException
MISCONF Redis is configured to save RDB snapshots, but it is currently not able to persist on disk. Commands that may modify the data set are disabled, because this instance is configured to report errors during writes if RDB snapshotting fails (stop-writes-on-bgsave-error option). Please check the Redis logs for details about the RDB error. RedisException thrown with message "MISCONF Redis is configured to save RDB snapshots, but it is currently not able to persist on disk. Commands that may modify the data set are disabled, because this instance is configured to report errors during writes if RDB snapshotting fails (stop-writes-on-bgsave-error option). Please check the Redis logs for details about the RDB error." Stacktrace: #12 RedisException in /home/deploy/EHungry-8-boyan/Web/classes/Cache.class.php:69 #11 Redis:setex in /home/deploy/EHungry-8-boyan/Web/classes/Cache.class.php:69 #10 Cache:Set in /home/deploy/EHungry-8-boyan/Web/classes/Cache.class.php:57 #9 Cache:SetArray in /home/deploy/EHungry-8-boyan/Web/classes/ClosedHours.class.php:142 #8 ClosedHours:getByDateAndTypeAndRestaurantOrCategory in /home/deploy/EHungry-8-boyan/Web/classes/ClosedHours.class.php:95 #7 ClosedHours:getByDateAndRestaurantAndType in /home/deploy/EHungry-8-boyan/Web/classes/Restaurant.class.php:2378 #6 Restaurant:getAvailableTimes in /home/deploy/EHungry-8-boyan/Web/classes/Restaurant.class.php:2654 #5 Restaurant:getAvailableDates in /home/deploy/EHungry-8-boyan/Web/classes/Restaurant.class.php:2720 #4 Restaurant:getOrderingDaysForAnyType in /home/deploy/EHungry-8-boyan/Web/lib/global.php:1009 #3 isOrderingClosed in /home/deploy/EHungry-8-boyan/Web/templates3.0/customer/mycart.php:16 #2 include in /home/deploy/EHungry-8-boyan/Web/templates3.0/customer/header.php:654 #1 include_once in /home/deploy/EHungry-8-boyan/Web/controllers/customer.php:867 #0 require in /home/deploy/EHungry-8-boyan/Web/index.php:30
Stack frames (13)
12
RedisException
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Cache.class.php
69
11
Redis
setex
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Cache.class.php
69
10
Cache
Set
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Cache.class.php
57
9
Cache
SetArray
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
ClosedHours.class.php
142
8
ClosedHours
getByDateAndTypeAndRestaurantOrCategory
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
ClosedHours.class.php
95
7
ClosedHours
getByDateAndRestaurantAndType
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Restaurant.class.php
2378
6
Restaurant
getAvailableTimes
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Restaurant.class.php
2654
5
Restaurant
getAvailableDates
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Restaurant.class.php
2720
4
Restaurant
getOrderingDaysForAnyType
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
lib
/
global.php
1009
3
isOrderingClosed
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
templates3.0
/
customer
/
mycart.php
16
2
include
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
templates3.0
/
customer
/
header.php
654
1
include_once
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
controllers
/
customer.php
867
0
require
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
index.php
30
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Cache.class.php
    }
 
    public static function SetObject($key, $var, $expire = 86400) {
        return static::Set($key, serialize($var), $expire);
    }
 
    public static function SetArray($key, $var, $expire = 86400) {
        return static::Set($key, serialize($var), $expire);
    }
 
    public static function SetBoolean($key, $var, $expire = 86400) {
        return static::Set($key, serialize($var), $expire);
    }
 
    public static function Set($key, $var, $expire = 86400) {
        App::debugbarLog('debug', "Cache set: $key");
        if ($i = static::getInstance()) {
            $var = static::beforeSet($var);
            return $expire > 0?
                $i->setEx($key, $expire, $var) :
                $i->set($key, $var);
        }
        return null;
    }
 
    public static function Exists(...$key):?bool {
        if ($i = static::getInstance()) {
            return $i->exists($key);
        }
        return null;
    }
 
    public static function Expire($key, $ttl) {
        if ($i = static::getInstance()) {
            return $i->expire($key, $ttl);
        }
        return false;
    }
 
    /**
Arguments
  1. "MISCONF Redis is configured to save RDB snapshots, but it is currently not able to persist on disk. Commands that may modify the data set are disabled, because this instance is configured to report errors during writes if RDB snapshotting fails (stop-writes-on-bgsave-error option). Please check the Redis logs for details about the RDB error."
    
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Cache.class.php
    }
 
    public static function SetObject($key, $var, $expire = 86400) {
        return static::Set($key, serialize($var), $expire);
    }
 
    public static function SetArray($key, $var, $expire = 86400) {
        return static::Set($key, serialize($var), $expire);
    }
 
    public static function SetBoolean($key, $var, $expire = 86400) {
        return static::Set($key, serialize($var), $expire);
    }
 
    public static function Set($key, $var, $expire = 86400) {
        App::debugbarLog('debug', "Cache set: $key");
        if ($i = static::getInstance()) {
            $var = static::beforeSet($var);
            return $expire > 0?
                $i->setEx($key, $expire, $var) :
                $i->set($key, $var);
        }
        return null;
    }
 
    public static function Exists(...$key):?bool {
        if ($i = static::getInstance()) {
            return $i->exists($key);
        }
        return null;
    }
 
    public static function Expire($key, $ttl) {
        if ($i = static::getInstance()) {
            return $i->expire($key, $ttl);
        }
        return false;
    }
 
    /**
Arguments
  1. "ch_r9913_saturday_PICKUP_0"
    
  2. 86400
    
  3. "a:2:{i:0;O:11:"ClosedHours":27:{s:12:"pdfPageCount";i:0;s:10:"timestamps";b:0;s:9:"\x00*\x00hidden";a:1:{i:0;s:8:"password";}s:12:"\x00*\x00nullables";a:0:{}s:13:"\x00*\x00connection";N;s:8:"\x00*\x00table";N;s:13:"\x00*\x00primaryKey";s:2:"id";s:10:"\x00*\x00keyType";s:3:"int";s:12:"incrementing";b:1;s:7:"\x00*\x00with";a:0:{}s:12:"\x00*\x00withCount";a:0:{}s:10:"\x00*\x00perPage";i:15;s:6:"exists";b:1;s:18:"wasRecentlyCreated";b:0;s:13:"\x00*\x00attributes";a:19:{s:2:"id";i:21270;s:10:"account_id";i:83437;s:13:"restaurant_id";i:9913;s:10:"start_time";s:8:"22:00:00";s:8:"end_time";s:8:"23:59:00";s:6:"monday";i:1;s:7:"tuesday";i:1;s:9:"wednesday";i:1;s:8:"thursday";i:1;s:6:"friday";i:1;s:8:"saturday";i:1;s:6:"sunday";i:1;s:7:"message";s:0:"";s:6:"pickup";i:1;s:8:"delivery";i:1;s:6:"dinein";i:1;s:17:"ordering_disabled";i:1;s:11:"category_id";N;s:25:"show_category_when_closed";i:0;}s:11:"\x00*\x00original";a:19:{s:2:"id";i:21270;s:10:"account_id";i:83437;s:13:"restaurant_id";i:9913;s:10:"start_time";s:8:"22:00:00";s:8:"end_time";s:8:"23:59:00";s:6:"monday";i:1;s:7:"tuesday";i:1;s:9:"wednesday";i:1;s:8:"thursday";i:1;s:6:"friday";i:1;s:8:"saturday";i:1;s:6:"sunday";i:1;s:7:"message";s:0:"";s:6:"pickup";i:1;s:8:"delivery";i:1;s:6:"dinein";i:1;s:17:"ordering_disabled";i:1;s:11:"category_id";N;s:25:"show_category_when_closed";i:0;}s:8:"\x00*\x00casts";a:0:{}s:8:"\x00*\x00dates";a:0:{}s:13:"\x00*\x00dateFormat";N;s:10:"\x00*\x00appends";a:0:{}s:9:"\x00*\x00events";a:0:{}s:14:"\x00*\x00observables";a:0:{}s:12:"\x00*\x00relations";a:0:{}s:10:"\x00*\x00touches";a:0:{}s:10:"\x00*\x00visible";a:0:{}s:11:"\x00*\x00fillable";a:0:{}s:10:"\x00*\x00guarded";a:1:{i:0;s:1:"*";}}i:1;O:11:"ClosedHours":27:{s:12:"pdfPageCount";i:0;s:10:"timestamps";b:0;s:9:"\x00*\x00hidden";a:1:{i:0;s:8:"password";}s:12:"\x00*\x00nullables";a:0:{}s:13:"\x00*\x00connection";N;s:8:"\x00*\x00table";N;s:13:"\x00*\x00primaryKey";s:2:"id";s:10:"\x00*\x00keyType";s:3:"int";s:12:"incrementing";b:1;s:7:"\x00*\x00with";a:0:{}s:12:"\x00*\x00withCount";a:0:{}s:10:"\x00*\x00perPage";i:15;s:6:"exists";b:1;s:18:"wasRecentlyCreated";b:0;s:13:"\x00*\x00attributes";a:19:{s:2:"id";i:21269;s:10:"account_id";i:83437;s:13:"restaurant_id";i:9913;s:10:"start_time";s:8:"00:00:00";s:8:"end_time";s:8:"06:00:00";s:6:"monday";i:1;s:7:"tuesday";i:1;s:9:"wednesday";i:1;s:8:"thursday";i:1;s:6:"friday";i:1;s:8:"saturday";i:1;s:6:"sunday";i:1;s:7:"message";s:0:"";s:6:"pickup";i:1;s:8:"delivery";i:1;s:6:"dinein";i:1;s:17:"ordering_disabled";i:1;s:11:"category_id";N;s:25:"show_category_when_closed";i:0;}s:11:"\x00*\x00original";a:19:{s:2:"id";i:21269;s:10:"account_id";i:83437;s:13:"restaurant_id";i:9913;s:10:"start_time";s:8:"00:00:00";s:8:"end_time";s:8:"06:00:00";s:6:"monday";i:1;s:7:"tuesday";i:1;s:9:"wednesday";i:1;s:8:"thursday";i:1;s:6:"friday";i:1;s:8:"saturday";i:1;s:6:"sunday";i:1;s:7:"message";s:0:"";s:6:"pickup";i:1;s:8:"delivery";i:1;s:6:"dinein";i:1;s:17:"ordering_disabled";i:1;s:11:"category_id";N;s:25:"show_category_when_closed";i:0;}s:8:"\x00*\x00casts";a:0:{}s:8:"\x00*\x00dates";a:0:{}s:13:"\x00*\x00dateFormat";N;s:10:"\x00*\x00appends";a:0:{}s:9:"\x00*\x00events";a:0:{}s:14:"\x00*\x00observables";a:0:{}s:12:"\x00*\x00relations";a:0:{}s:10:"\x00*\x00touches";a:0:{}s:10:"\x00*\x00visible";a:0:{}s:11:"\x00*\x00fillable";a:0:{}s:10:"\x00*\x00guarded";a:1:{i:0;s:1:"*";}}}"
    
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Cache.class.php
                if (!@static::$redisObj->connect(static::$host, (int)static::$port)) {
                    static::$redisObj = false;
                    Splunk::log(Splunk::LOG_REDIS_CONN, ['error' => 'Error connecting']);
                } else {
                    static::$redisObj->select(static::$db);
                }
            } catch (RedisException $e) {
                static::$redisObj = false;
                Splunk::log(Splunk::LOG_REDIS_CONN, ['error' => 'Error connecting: '.$e->getMessage()]);
            }
        }
        return static::$redisObj;
    }
 
    public static function SetObject($key, $var, $expire = 86400) {
        return static::Set($key, serialize($var), $expire);
    }
 
    public static function SetArray($key, $var, $expire = 86400) {
        return static::Set($key, serialize($var), $expire);
    }
 
    public static function SetBoolean($key, $var, $expire = 86400) {
        return static::Set($key, serialize($var), $expire);
    }
 
    public static function Set($key, $var, $expire = 86400) {
        App::debugbarLog('debug', "Cache set: $key");
        if ($i = static::getInstance()) {
            $var = static::beforeSet($var);
            return $expire > 0?
                $i->setEx($key, $expire, $var) :
                $i->set($key, $var);
        }
        return null;
    }
 
    public static function Exists(...$key):?bool {
        if ($i = static::getInstance()) {
            return $i->exists($key);
Arguments
  1. "ch_r9913_saturday_PICKUP_0"
    
  2. "a:2:{i:0;O:11:"ClosedHours":27:{s:12:"pdfPageCount";i:0;s:10:"timestamps";b:0;s:9:"\x00*\x00hidden";a:1:{i:0;s:8:"password";}s:12:"\x00*\x00nullables";a:0:{}s:13:"\x00*\x00connection";N;s:8:"\x00*\x00table";N;s:13:"\x00*\x00primaryKey";s:2:"id";s:10:"\x00*\x00keyType";s:3:"int";s:12:"incrementing";b:1;s:7:"\x00*\x00with";a:0:{}s:12:"\x00*\x00withCount";a:0:{}s:10:"\x00*\x00perPage";i:15;s:6:"exists";b:1;s:18:"wasRecentlyCreated";b:0;s:13:"\x00*\x00attributes";a:19:{s:2:"id";i:21270;s:10:"account_id";i:83437;s:13:"restaurant_id";i:9913;s:10:"start_time";s:8:"22:00:00";s:8:"end_time";s:8:"23:59:00";s:6:"monday";i:1;s:7:"tuesday";i:1;s:9:"wednesday";i:1;s:8:"thursday";i:1;s:6:"friday";i:1;s:8:"saturday";i:1;s:6:"sunday";i:1;s:7:"message";s:0:"";s:6:"pickup";i:1;s:8:"delivery";i:1;s:6:"dinein";i:1;s:17:"ordering_disabled";i:1;s:11:"category_id";N;s:25:"show_category_when_closed";i:0;}s:11:"\x00*\x00original";a:19:{s:2:"id";i:21270;s:10:"account_id";i:83437;s:13:"restaurant_id";i:9913;s:10:"start_time";s:8:"22:00:00";s:8:"end_time";s:8:"23:59:00";s:6:"monday";i:1;s:7:"tuesday";i:1;s:9:"wednesday";i:1;s:8:"thursday";i:1;s:6:"friday";i:1;s:8:"saturday";i:1;s:6:"sunday";i:1;s:7:"message";s:0:"";s:6:"pickup";i:1;s:8:"delivery";i:1;s:6:"dinein";i:1;s:17:"ordering_disabled";i:1;s:11:"category_id";N;s:25:"show_category_when_closed";i:0;}s:8:"\x00*\x00casts";a:0:{}s:8:"\x00*\x00dates";a:0:{}s:13:"\x00*\x00dateFormat";N;s:10:"\x00*\x00appends";a:0:{}s:9:"\x00*\x00events";a:0:{}s:14:"\x00*\x00observables";a:0:{}s:12:"\x00*\x00relations";a:0:{}s:10:"\x00*\x00touches";a:0:{}s:10:"\x00*\x00visible";a:0:{}s:11:"\x00*\x00fillable";a:0:{}s:10:"\x00*\x00guarded";a:1:{i:0;s:1:"*";}}i:1;O:11:"ClosedHours":27:{s:12:"pdfPageCount";i:0;s:10:"timestamps";b:0;s:9:"\x00*\x00hidden";a:1:{i:0;s:8:"password";}s:12:"\x00*\x00nullables";a:0:{}s:13:"\x00*\x00connection";N;s:8:"\x00*\x00table";N;s:13:"\x00*\x00primaryKey";s:2:"id";s:10:"\x00*\x00keyType";s:3:"int";s:12:"incrementing";b:1;s:7:"\x00*\x00with";a:0:{}s:12:"\x00*\x00withCount";a:0:{}s:10:"\x00*\x00perPage";i:15;s:6:"exists";b:1;s:18:"wasRecentlyCreated";b:0;s:13:"\x00*\x00attributes";a:19:{s:2:"id";i:21269;s:10:"account_id";i:83437;s:13:"restaurant_id";i:9913;s:10:"start_time";s:8:"00:00:00";s:8:"end_time";s:8:"06:00:00";s:6:"monday";i:1;s:7:"tuesday";i:1;s:9:"wednesday";i:1;s:8:"thursday";i:1;s:6:"friday";i:1;s:8:"saturday";i:1;s:6:"sunday";i:1;s:7:"message";s:0:"";s:6:"pickup";i:1;s:8:"delivery";i:1;s:6:"dinein";i:1;s:17:"ordering_disabled";i:1;s:11:"category_id";N;s:25:"show_category_when_closed";i:0;}s:11:"\x00*\x00original";a:19:{s:2:"id";i:21269;s:10:"account_id";i:83437;s:13:"restaurant_id";i:9913;s:10:"start_time";s:8:"00:00:00";s:8:"end_time";s:8:"06:00:00";s:6:"monday";i:1;s:7:"tuesday";i:1;s:9:"wednesday";i:1;s:8:"thursday";i:1;s:6:"friday";i:1;s:8:"saturday";i:1;s:6:"sunday";i:1;s:7:"message";s:0:"";s:6:"pickup";i:1;s:8:"delivery";i:1;s:6:"dinein";i:1;s:17:"ordering_disabled";i:1;s:11:"category_id";N;s:25:"show_category_when_closed";i:0;}s:8:"\x00*\x00casts";a:0:{}s:8:"\x00*\x00dates";a:0:{}s:13:"\x00*\x00dateFormat";N;s:10:"\x00*\x00appends";a:0:{}s:9:"\x00*\x00events";a:0:{}s:14:"\x00*\x00observables";a:0:{}s:12:"\x00*\x00relations";a:0:{}s:10:"\x00*\x00touches";a:0:{}s:10:"\x00*\x00visible";a:0:{}s:11:"\x00*\x00fillable";a:0:{}s:10:"\x00*\x00guarded";a:1:{i:0;s:1:"*";}}}"
    
  3. 86400
    
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
ClosedHours.class.php
        if ($aObj || is_null($aObj)) {
            return $aObj;
        }
 
        $db_conn = DB::conn();
        $rbs = array();
        if ($cid && $isHiddenToCustomers) {
            $sql .= ' AND show_category_when_closed = 0';
        }
        $sql = "SELECT * FROM ".ClosedHours::getTableName()." WHERE (restaurant_id = ? OR category_id = ?) ".$sql." ORDER BY id DESC";
        $db_conn->bindParameter($sql, 1, $rid, "integer");
        $db_conn->bindParameter($sql, 1, $cid, "integer");
        $result = $db_conn->query($sql);
        if ($result && $result->rowCount() > 0) {
            while ($row = $result->fetch()) {
                $ch = new ClosedHours();
                $ch->loadFromArray($row, true);
                $rbs[] = $ch;
            }
            Cache::SetArray($cacheKey, $rbs);
            return $rbs;
        }
        Cache::SetObject($cacheKey, null);
        return null;
    }
    
    public static function clearCache($rid, $cid = null) {
        global $days;
        $types = ['PICKUP', 'DINEIN', 'DELIVERY'];
        $isHiddenToCustomersArray = [0, 1];
        foreach ($days as $d) {
            foreach ($types as $t) {
                foreach ($isHiddenToCustomersArray as $isHiddenToCustomers) {
                    Cache::Delete('ch_'.($cid > 0? ('c'.$cid) : ('r'.$rid)).'_'.mb_strtolower($d).'_'.$t.'_'.$isHiddenToCustomers);
                }
            }
        }
    }
 
    public function toString() {
Arguments
  1. "ch_r9913_saturday_PICKUP_0"
    
  2. array:2 [
      0 => ClosedHours {}
      1 => ClosedHours {}
    ]
    
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
ClosedHours.class.php
        }
        if (!$time) {
            $time = $restaurant->getLocalTime();
        }
        $closedHours = ClosedHours::getByDateAndCategoryAndType($time, $category->getId(), $orderType, $isHiddenToCustomers);
        if (is_array($closedHours) && count($closedHours) > 0) {
            return $closedHours;
        }
        //check parent category too
        if ($category->getParentId()) {
            $closedHours = ClosedHours::getByDateAndCategoryAndType($time, $category->getParentId(), $orderType, $isHiddenToCustomers);
            if (is_array($closedHours) && count($closedHours) > 0) {
                return $closedHours;
            }
        }
        return false;
    }
 
    public static function getByDateAndRestaurantAndType($time = null, $rid = -1, $type = 'PICKUP') {
        return ClosedHours::getByDateAndTypeAndRestaurantOrCategory($time, $rid, null, $type);
    }
 
    public static function getByDateAndCategoryAndType($time = null, $cid = null, $type = 'PICKUP', $isHiddenToCustomers = false) {
        return ClosedHours::getByDateAndTypeAndRestaurantOrCategory($time, -1, $cid, $type, $isHiddenToCustomers);
    }
 
    public static function getByDateAndTypeAndRestaurantOrCategory($time = null, $rid = -1, $cid = -1, $type = 'PICKUP', $isHiddenToCustomers = false) {
        $day = mb_strtolower(date('l', $time));
        $sql = " AND ".$day." = 1";
 
        if (!$type) {
            $type = 'PICKUP';
        }
        switch ($type) {
            case 'PICKUP':
                $sql .= " AND pickup=1 ";
                break;
            case 'DELIVERY':
                $sql .= " AND delivery=1 ";
                break;
Arguments
  1. 1769846400
    
  2. 9913
    
  3. null
    
  4. "PICKUP"
    
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Restaurant.class.php
                if (empty($startEndArray[$i-1]['00:00']) && $prevclose < $prevopen) {
                    $startEndArray[$i-1]['00:00'] = $prevclose;
                    $prevDayClose = $prevclose;
                }
            }
        }
 
        //if there are holiday hours for this day - only return these hours
        $startEndInvalidArray = [];
        if (!$excludingClosedHours) {
            $holidayHours = HolidayHours::getByDateAndRestaurantAndType(date('Y-m-d 00:00:00', $dateTimestamp), $this->getId(), $cart->getBaseOrderType());
            if (is_object($holidayHours)) {
                $startTime     = date('H:i', strtotime($holidayHours->getStartHour()));
                $endTime       = date('H:i', strtotime($holidayHours->getEndHour()));
                $startEndArray = [[$startTime => $endTime]];
                $openTimes = [$startTime];
            }
 
            //remove times from closed hours
            $closedHours = ClosedHours::getByDateAndRestaurantAndType($dateTimestamp, $this->getId(), $cart->getBaseOrderType());
            if (!is_object($holidayHours) && is_array($closedHours) && count($closedHours) > 0) {
                foreach ($closedHours as $h) {
                    $startTime              = date('H:i', strtotime($h->getStartTime()));
                    $endTime                = date('H:i', strtotime($h->getEndTime()));
                    $startEndInvalidArray[] = [$startTime => $endTime];
                }
            }
        }
 
        //menu available times
        $prevDayMenusClose = null;
        $allPrevDayMenuClosed = true;
        $onePrevDayMenuClosed = false;
        $getTimesForAnyMenus = false;
        if ($menus === null) {
            $menus = $cart->getMenus();
        }
        if (!count($menus)) {
            $menus = $this->getActiveMenus(true);
            $getTimesForAnyMenus = true;
Arguments
  1. 1769846400
    
  2. 9913
    
  3. "PICKUP"
    
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Restaurant.class.php
 
            //disable days for when the cart items' category is closed
            $categories = $cart->getCartItemsCategories();
            foreach ($categories as $category) {
                $isCategoryHidden = ClosedHours::isCategoryDisabled($this, $category, $currentLocalTime, false, $orderType) || HolidayHours::isCategoryDisabled($this, $category, $currentLocalTime, false, $orderType);
                if ($isCategoryHidden) {
                    $closed = true;
                }
            }
 
            //ordering closed
            $closedUntil = $this->getLocalPublicOrderingClosedUntilText(true, $orderType);
            if ($closedUntil && strtotime(date('Y-m-d', $closedUntil)) > strtotime(date('Y-m-d', $currentLocalTime))) {
                $closed = true;
            }
 
            $dateCurrent = date('Y-m-d', $currentLocalTime);
            if (!$closed) {
                //if no times are available on that day - show whole day as unavailable
                $times = $this->getAvailableTimes(new DateTime($dateCurrent), $excludeClosedHours, $menus, $ignoreOrderingDaysLimit, $excludeHoursPastClosing);
                if (count($times)) {
                    $ymd = date('Y-m-d', $currentLocalTime);
                    $availableDates[$ymd] = $ymd;
                }
            }
        }
 
        $cart->setBaseOrderType($savedOrderType);
        $cart->updateToSession();
 
        $cache[$cacheKey] = $availableDates;
 
        if ($returnAsKeys) {
            return $availableDates;
        } else {
            return array_values($availableDates);
        }
    }
 
    public function hasAvailableDays($selectedTime, $orderType) {
Arguments
  1. DateTime @1769846400 {
      date: 2026-01-31 00:00:00.0 America/Los_Angeles (-08:00)
    }
    
  2. false
    
  3. []
    
  4. false
    
  5. false
    
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
classes
/
Restaurant.class.php
     * @param bool $ignoreDaysLimit
     * @param Menu[] $menus
     * @return array
     * @throws Exception
     */
    public function getOrderingDaysForAnyType($ignoreDaysLimit = false, $menus = []) {
        // Use a static variable to store cache within the request scope, so we don't recalculate this on every call within the request
        static $cache = [];
        $cacheKey = ($ignoreDaysLimit ? '1' : '0') .
            ($menus === null ? 'null' : md5(json_encode($menus)));
 
        if (isset($cache[$cacheKey])) {
            return $cache[$cacheKey];
        }
 
        $orderTypes = $this->getEnabledBaseOrderTypes();
        $availableDates = [];
        $dateTime = new DateTime(date('Y-m-d', $this->getLocalTime()));
        if (isset($orderTypes["PICKUP"]) || isset($orderTypes["DINEIN"])) {
            $availableDates = $this->getAvailableDates($dateTime, 'PICKUP', false, $ignoreDaysLimit, false, $menus);
        }
        if (isset($orderTypes["DELIVERY"])) {
            $availableDates = array_merge($availableDates, $this->getAvailableDates($dateTime, 'DELIVERY', false, $ignoreDaysLimit, false, $menus));
        }
        sort($availableDates);
        $cache[$cacheKey] = $availableDates;
        return $availableDates;
    }
 
    /**
     * @param DateTime $date
     * @return array
     */
    public function getAvailableTimeSlots($date) {
        //time slots
        if ($this->time_slots_enabled) {
            $validTimes = $this->getAvailableTimes($date);
            $timeSlots = RestaurantTimeSlot::getForRestaurant($this);
            $validTimeSlots = [];
 
Arguments
  1. DateTime @1769760000 {
      date: 2026-01-30 00:00:00.0 America/Los_Angeles (-08:00)
    }
    
  2. "PICKUP"
    
  3. false
    
  4. false
    
  5. false
    
  6. []
    
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
lib
/
global.php
            }
 
            if ($restaurant->public_ordering_closed_until) {
                return $restaurant->getLocalPublicOrderingClosedUntilText($returnClosedUntilTime);
            }
        }
        if (is_string($defaultMsg)) {
            return $returnClosedUntilTime ? 'Indefinitely' : $defaultMsg;
        }
 
        return $returnClosedUntilTime ? 'Indefinitely' : ($result?: true); //in case result is an empty string
    }
 
    if ($skipLoginCheck && is_object($restaurant) && $restaurant->isOrderingClosed()) {
        return true;
    }
 
    //If no ordering times are currently available, check if ordering will be possible later.
    //If not, return "Online ordering is closed" (effective indefinitely, represented as +200 years)
    if (is_object($restaurant) && count($restaurant->getOrderingDaysForAnyType()) === 0) {
        $firstAvailableTime = $restaurant->getFirstAvailableTime();
        if ($firstAvailableTime) {
            return $returnClosedUntilTime ? $firstAvailableTime
                : ('Online ordering is closed' . (' until ' . date('F jS \a\t g:iA', $firstAvailableTime)));
        }
        return $returnClosedUntilTime ? strtotime('+200 years') : 'Online ordering is closed';
    }
 
    return false;
}
 
function addErrorDialogueToLoadEvent() {
    if (!isset($_REQUEST['hide_error_dialog'])) {
        $errStr = str_replace("'", "&lsquo;", $_REQUEST['errors']);
        $errStr = preg_replace('/\r\n/', ' ', $errStr);
        if ($errStr) {
            return '<script type="text/javascript" defer="defer">
            var tmpOnload = window.onload;
            window.onload = function() {
                if(tmpOnload) tmpOnload();
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
templates3.0
/
customer
/
mycart.php
<input type="hidden" id="last-cart-action" value="<?=$_GET['cartaction'] ?? ''?>" />
 
<? function no_items($msg) { // phpcs:ignore ?>
    <div class="inner">
        <div class="item">
            <span class="noitems"><?=$msg?></span>
        </div>
    </div>
<? }
 
if (isset($errMsg)) {
    no_items($errMsg);
}
 
if ($closed_msg =
    isOrderingClosed(CLOSED_MSG_RESTAURANT) ?:
    (isset($restaurant)? $restaurant->generateHasNoOrderingMsg() : false) //TODO PHP8 nullsafe call
) {
    $cart->clear();
    no_items($closed_msg);
} else {
    $cartItemCount = $cart->getCartItemCount();
    if ($cartItemCount) {
        $cartItems = $cart->getCartItems();
?>
        <div class="inner">
<?
        foreach ($cartItems as $key => $i) {
            $cart_counter++;
            $price = $i->getSelectedPrice();
?>
            <div class="item">
                <div class="itemTop">
                    <div class="l">
                        <strong class="h4"><?=$i->getDisplayName()?></strong>
                        <p class="description">
                            <?=intToMoneyString((int)$i->getTotalPriceValue()) . " ea. ".(trim($price->getDisplayName())!=trim($i->getDisplayName())?("(".$price->getDisplayName().")"):"")?>
                        </p>
                    </div>
                    <div class="m">
Arguments
  1. "RESTAURANT"
    
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
templates3.0
/
customer
/
header.php
                        include(CORE_PATH . "templates3.0/customer/widgets/footersmallnav.php");
                    } ?>
                    <hr>
                    <div class="recaptcha-terms">This site is protected by reCAPTCHA and the Google <a href="https://policies.google.com/privacy">Privacy Policy</a> and <a href="https://policies.google.com/terms">Terms of Service</a> apply.</div>
                </div>
            </div>
        </div>
 
        <div class="cart isClosed" id="cart">
            <div class="cartHeaderWrapper">
                <div class="p16" id="cartTriggerClose">
                    <i class="far fa-times fa-lg" role="presentation"></i>
                </div>
                <header>
                    <strong class="h3">Your order</strong>
                </header>
            </div>
            <div class="cartInner">
                <div class="cartInnerScroll">
                    <? include(CORE_PATH."templates3.0/customer/mycart.php"); ?>
                </div>
            </div>
        </div>
        <header class="header" style="<?=$account->logo_size == "vertical" ? "min-height:130px; " : ""?>">
            <div class="inner">
                <div class="logoContainer">
                    <? if (!isset($_REQUEST['_TEMPLATE_SETTINGS']['show_logo']) || $_REQUEST['_TEMPLATE_SETTINGS']['show_logo']->getValue() == 1) {?>
                        <a id="top-logo" href="<?=($account->getHomeLink())?$account->getHomeLink():formatCustomerLink('home')?>" class="logo" aria-hidden="true" tabindex="-1"><?
                            $noLogo = true;
                            if ($account->getLogoFileName()) {
                                $alt = MainNavigationTab::getTabName($account->id, 'home', 'Home');
                                $logoStyles = $account->getLogoSize() == "vertical" ? "height:250px; margin: 0 !important;" : "margin: 0 !important;";
                                if (strpos($account->getLogoFileName(), '_1x') !== false) {
                                    $noLogo = false;
                                    echo '<img src="' . $account->getUrl('logoFileName') .'" srcset="' . $account->getUrl('logoFileName') . ' 1x, ' . $account->getResponsiveUrl('logoFileName', '2x') . ' 2x" alt="'.$alt.'" style="'.$logoStyles.'">';
                                } else {
                                    $noLogo = false;
                                    echo '<img src="'.$account->getUrl('logoFileName').'" alt="'.$alt.'" style="'.$logoStyles.'" />';
                                }
                            }
Arguments
  1. "/home/deploy/EHungry-8-boyan/Web/templates3.0/customer/mycart.php"
    
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
controllers
/
customer.php
}
 
if (!isset($cart) || !is_object($cart)) {
    $GLOBALS['cart'] = \Cart::getCurrent();
}
 
//unset callback data in the event someone didn't hit the callback validation page
if (!in_array($_REQUEST['form'], ['checkout', 'nosuchpage', 'validatecallback', 'viewdeliveryzone'])) {
    //TODO: probably need to add one more form here that is called ajax, callback seems to reset when it shouldnt
    unset($_SESSION['validation_data']);
}
 
$locs = $account->getActiveRestaurants('position');
$tab = MainNavigationTab::getAllForAccount($account->getId());
 
include_once(CORE_PATH.'lib/helpers/customer3.0.php');
 
if (!in_array($_REQUEST['form'], $viewContentOnly)) {
    App::debugbarTime('header');
    include_once(getLayoutPartPath('header'));
    App::debugbarTime('header');
}
 
App::debugbarTime("view '{$_REQUEST['form']}'");
$path = CORE_PATH.'view' . ($_REQUEST['_VERSION'] == 4 ? 4 : 3) . '.0/customer/'.$_REQUEST['form'].'.php';
if (is_readable($path)) {
    include_once($path);
}
App::debugbarTime("view '{$_REQUEST['form']}'");
 
if (!in_array($_REQUEST['form'], $viewContentOnly)) {
    App::debugbarTime('footer');
    include_once(getLayoutPartPath('footer'));
    App::debugbarTime('footer');
}
 
function getLayoutPartPath($part) {
    if (isset($_REQUEST['_CORDOVA_APP'])) {
        $cart = Cart::getCurrent();
 
Arguments
  1. "/home/deploy/EHungry-8-boyan/Web/templates3.0/customer/header.php"
    
/
home
/
deploy
/
EHungry-8-boyan
/
Web
/
index.php
App::startTime();
 
ErrorHandlers::register();
 
// Global.php is the core setup file for the application
App::debugbarTime('Global.php');
require(dirname(__DIR__) . '/PHP/Global.php');
App::debugbarTime('Global.php');
/** @var string $controller The main controller - defined at /PHP/Global.php */
 
App::debugbarTime('Sentry - controller');
ErrorHandlers::sentryInit($controller); //doesn't always do much - not every controller has a Sentry project
App::debugbarTime('Sentry - controller');
 
App::debugbarTime("controller: $controller");
apache_note('AppController', $controller);
if (file_exists(CORE_PATH."lib/helpers/$controller.php")) {
    require CORE_PATH."lib/helpers/$controller.php";
}
require CORE_PATH."controllers/$controller.php";
App::debugbarTime("controller: $controller");
 
Arguments
  1. "/home/deploy/EHungry-8-boyan/Web/controllers/customer.php"
    

Environment & details:

Key Value
aid
"restaurant/orientalexpressaustin/customerregister/guest/1"
guest
"1"
Key Value
guest
"1"
empty
empty
Key Value
loc
"en_US"
customer_account_id
83437
cart
Cart {}
restaurant_id
9913
menu_id
12520
app_banner_shown
true
Key Value
UNIQUE_ID
"aXzY2sJgHI6gfJ4kqoUFJAAAAAg"
SCRIPT_URL
"/restaurant/orientalexpressaustin/customerregister/guest/1"
SCRIPT_URI
"http://www.springroll.com.8.boyan.ehungry.net/restaurant/orientalexpressaustin/customerregister/guest/1"
HTTP_HOST
"www.springroll.com.8.boyan.ehungry.net"
HTTP_X_REAL_IP
"216.73.216.37"
HTTP_X_FORWARDED_FOR
"216.73.216.37"
HTTP_X_CONFKEY
"Main_Domain:6462"
HTTP_SCHEME
"https"
HTTP_EHENV
"TODO"
HTTP_CONNECTION
"close"
HTTP_ACCEPT
"*/*"
HTTP_USER_AGENT
"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; ClaudeBot/1.0; +claudebot@anthropic.com)"
HTTP_ACCEPT_ENCODING
"gzip, br, zstd, deflate"
PATH
"/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin"
SERVER_SIGNATURE
""
SERVER_SOFTWARE
"Apache/2.4.66 () mod_wsgi/4.6.5 Python/3.7 PHP/7.2.34"
SERVER_NAME
"www.springroll.com.8.boyan.ehungry.net"
SERVER_ADDR
"127.0.0.1"
SERVER_PORT
"80"
REMOTE_ADDR
"127.0.0.1"
DOCUMENT_ROOT
"/home/deploy/EHungry-8-boyan/Web"
REQUEST_SCHEME
"http"
CONTEXT_PREFIX
""
CONTEXT_DOCUMENT_ROOT
"/home/deploy/EHungry-8-boyan/Web"
SERVER_ADMIN
"root@localhost"
SCRIPT_FILENAME
"/home/deploy/EHungry-8-boyan/Web/index.php"
REMOTE_PORT
"54248"
GATEWAY_INTERFACE
"CGI/1.1"
SERVER_PROTOCOL
"HTTP/1.0"
REQUEST_METHOD
"GET"
QUERY_STRING
"aid=restaurant/orientalexpressaustin/customerregister/guest/1"
REQUEST_URI
"/restaurant/orientalexpressaustin/customerregister/guest/1"
SCRIPT_NAME
"/restaurant/orientalexpressaustin/customerregister/guest/1"
PHP_SELF
"/restaurant/orientalexpressaustin/customerregister/guest/1"
REQUEST_TIME_FLOAT
1769789658.925
REQUEST_TIME
1769789658
empty
0. Whoops\Handler\PrettyPageHandler

Fatal error: Uncaught RedisException: MISCONF Redis is configured to save RDB snapshots, but it is currently not able to persist on disk. Commands that may modify the data set are disabled, because this instance is configured to report errors during writes if RDB snapshotting fails (stop-writes-on-bgsave-error option). Please check the Redis logs for details about the RDB error. in [no active file]:0 Stack trace: #0 {main} thrown in [no active file] on line 0