mirror of
https://github.com/shlinkio/shlink.git
synced 2025-02-15 09:53:33 -06:00
Removed logic making visits to be returned for 2 days only if no start or end date were provided
This commit is contained in:
parent
a9f480ca99
commit
15896045f3
@ -73,5 +73,8 @@
|
||||
"serve": "php -S 0.0.0.0:8000 -t public/",
|
||||
"test": "phpunit --coverage-clover build/clover.xml",
|
||||
"pretty-test": "phpunit --coverage-html build/coverage"
|
||||
},
|
||||
"config": {
|
||||
"process-timeout": 0
|
||||
}
|
||||
}
|
||||
|
@ -29,12 +29,6 @@ class VisitRepository extends EntityRepository implements VisitRepositoryInterfa
|
||||
$shortUrl = $shortUrl instanceof ShortUrl
|
||||
? $shortUrl
|
||||
: $this->getEntityManager()->find(ShortUrl::class, $shortUrl);
|
||||
if (! isset($dateRange) || $dateRange->isEmpty()) {
|
||||
$startDate = $shortUrl->getDateCreated();
|
||||
$endDate = clone $startDate;
|
||||
$endDate->add(new \DateInterval('P2D'));
|
||||
$dateRange = new DateRange($startDate, $endDate);
|
||||
}
|
||||
|
||||
$qb = $this->createQueryBuilder('v');
|
||||
$qb->where($qb->expr()->eq('v.shortUrl', ':shortUrl'))
|
||||
|
Loading…
Reference in New Issue
Block a user