Completed
Pull Request — master (#223)
by Andrzej
06:41
created

CrawlInternalUrls::__construct()   A

Complexity

Conditions 2
Paths 2

Size

Total Lines 8

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
c 0
b 0
f 0
dl 0
loc 8
rs 10
cc 2
nc 2
nop 1
1
<?php
2
3
namespace Spatie\Crawler;
4
5
use GuzzleHttp\Psr7\Uri;
6
use Psr\Http\Message\UriInterface;
7
8
class CrawlInternalUrls extends CrawlProfile
9
{
10
    public function shouldCrawl(UriInterface $url): bool
11
    {
12
        return $this->baseUrl->getHost() === $url->getHost();
13
    }
14
}
15