mirror of
https://github.com/shlinkio/shlink.git
synced 2024-11-27 08:18:24 +03:00
Added comments on places to change
This commit is contained in:
parent
1b4fc89b07
commit
f801f265ed
2 changed files with 3 additions and 1 deletions
|
@ -68,6 +68,7 @@ return [
|
|||
// This middleware is in front of tracking actions explicitly. Putting here for orphan visits tracking
|
||||
IpAddress::class,
|
||||
Core\ErrorHandler\NotFoundTypeResolverMiddleware::class,
|
||||
// TODO MultiSegmentCustomSlugRedirectMiddleware
|
||||
Core\ShortUrl\Middleware\ExtraPathRedirectMiddleware::class,
|
||||
Core\ErrorHandler\NotFoundTrackerMiddleware::class,
|
||||
Core\ErrorHandler\NotFoundRedirectHandler::class,
|
||||
|
|
|
@ -45,10 +45,11 @@ class RequestTracker implements RequestTrackerInterface, RequestMethodInterface
|
|||
$notFoundType = $request->getAttribute(NotFoundType::class);
|
||||
$visitor = Visitor::fromRequest($request);
|
||||
|
||||
match (true) { // @phpstan-ignore-line
|
||||
match (true) {
|
||||
$notFoundType?->isBaseUrl() => $this->visitsTracker->trackBaseUrlVisit($visitor),
|
||||
$notFoundType?->isRegularNotFound() => $this->visitsTracker->trackRegularNotFoundVisit($visitor),
|
||||
$notFoundType?->isInvalidShortUrl() => $this->visitsTracker->trackInvalidShortUrlVisit($visitor),
|
||||
default => null,
|
||||
};
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue