private function isPubDirectory($sitePath, $route, $pub = '')
    {
        $sitePath .= '/pub/';
        $dirs = glob($sitePath . '*', GLOB_ONLYDIR);

        $dirs = str_replace($sitePath, '', $dirs);
        foreach ($dirs as $dir) {
            if (strpos($route, $pub . $dir . '/') === 0) {
                return true;
            }
        }
        return false;
    }
private function isPubDirectory($sitePath, $route, $pub = '')
    {
        $sitePath .= '/pub/';
        $dirs = glob($sitePath . '*', GLOB_ONLYDIR);

        $dirs = str_replace($sitePath, '', $dirs);
        foreach ($dirs as $dir) {
            if (strpos($route, $pub . $dir . '/') === 0) {
                return true;
            }
        }
        return false;
    }
private function isPubDirectory ( $ sitePath , $ route , $ pub = '' ) { $ sitePath .= '/pub/' ; $ dirs = glob ( $ sitePath . '*' , GLOB_ONLYDIR ) ; $ dirs = str_replace ( $ sitePath , '' , $ dirs ) ; foreach ( $ dirs as $ dir ) { if ( strpos ( $ route , $ pub . $ dir . '/' ) === 0 ) { return true ; } } return false ; }
Checks to see if route is referencing any directory inside pub. This is a dynamic check so that if any new
directories are added to pub this driver will not need to be updated.

@param string $sitePath
@param string $route
@param string $pub
@return bool
Checks to see if route is referencing any directory inside pub . This is a dynamic check so that if any new directories are added to pub this driver will not need to be updated .