Updated LocateShortUrlVisit so that it dispatches a VisitLocated event

This commit is contained in:
Alejandro Celaya
2019-12-28 13:07:11 +01:00
parent 4886825564
commit b17bcb6c93
6 changed files with 58 additions and 14 deletions

View File

@@ -0,0 +1,28 @@
<?php
declare(strict_types=1);
namespace Shlinkio\Shlink\Core\EventDispatcher;
use JsonSerializable;
final class VisitLocated implements JsonSerializable
{
/** @var string */
private $visitId;
public function __construct(string $visitId)
{
$this->visitId = $visitId;
}
public function visitId(): string
{
return $this->visitId;
}
public function jsonSerialize(): array
{
return ['visitId' => $this->visitId];
}
}