Skip to content

Commit

Permalink
make constructor public
Browse files Browse the repository at this point in the history
  • Loading branch information
cosmastech committed Jul 5, 2024
1 parent aad027e commit a49becc
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/Adapters/Datadog/DatadogStatsDClientAdapter.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,16 +12,11 @@ class DatadogStatsDClientAdapter implements StatsDClientAdapter, TagNormalizerAw
{
use TagNormalizerAwareTrait;

protected function __construct(protected readonly DogStatsd $datadogClient)
public function __construct(protected readonly DogStatsd $datadogClient)
{
$this->tagNormalizer = new NoopTagNormalizer();
}

public static function fromConfig(array $config): static
{
return new static(new DogStatsd($config));
}

public function timing(string $stat, float $durationMs, float $sampleRate = 1.0, array $tags = []): void
{
$this->datadogClient->timing($stat, $durationMs, $sampleRate, $this->normalizeTags($tags));
Expand Down

0 comments on commit a49becc

Please sign in to comment.