src/Kunstmaan/AdminBundle/Helper/AdminRouteHelper.php
public function isAdminRoute($url)
    {
        if ($this->matchesPreviewRoute($url)) {
            return false;
        }

        preg_match(sprintf(self::$ADMIN_MATCH_REGEX, $this->adminKey), $url, $matches);

        // Check if path is part of admin area
        if (count($matches) === 0) {
            return false;
        }

        return true;
    }
public function isAdminRoute($url)
    {
        if ($this->matchesPreviewRoute($url)) {
            return false;
        }

        preg_match(sprintf(self::$ADMIN_MATCH_REGEX, $this->adminKey), $url, $matches);

        // Check if path is part of admin area
        if (count($matches) === 0) {
            return false;
        }

        return true;
    }
public function isAdminRoute ( $ url ) { if ( $ this -> matchesPreviewRoute ( $ url ) ) { return false ; } preg_match ( sprintf ( self :: $ ADMIN_MATCH_REGEX , $ this -> adminKey ) , $ url , $ matches ) ; // Check if path is part of admin area if ( count ( $ matches ) === 0 ) { return false ; } return true ; }
Checks wether the given url points to an admin route

@param string $url

@return bool
Checks wether the given url points to an admin route