Do not dispatch async job for matomo if disabled

This commit is contained in:
Alejandro Celaya
2023-11-15 20:02:35 +01:00
parent 9dbd15bc0c
commit f88d57b2b6
4 changed files with 12 additions and 4 deletions

View File

@@ -7,11 +7,11 @@ namespace Shlinkio\Shlink\Core\Matomo;
class MatomoOptions
{
public function __construct(
public readonly bool $enabled,
public readonly ?string $baseUrl,
public readonly bool $enabled = false,
public readonly ?string $baseUrl = null,
/** @var numeric-string|int|null */
private readonly string|int|null $siteId,
public readonly ?string $apiToken,
private readonly string|int|null $siteId = null,
public readonly ?string $apiToken = null,
) {
}