Skip to content

Commit

Permalink
Type hint float on metrics calls (#1745)
Browse files Browse the repository at this point in the history
  • Loading branch information
stayallive authored May 28, 2024
1 parent 82d9593 commit 7a51be0
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/Metrics/Metrics.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,11 @@ public static function getInstance(): self
}

/**
* @param int|float $value
* @param array<string, string> $tags
*/
public function increment(
string $key,
$value,
float $value,
?MetricsUnit $unit = null,
array $tags = [],
?int $timestamp = null,
Expand All @@ -63,12 +62,11 @@ public function increment(
}

/**
* @param int|float $value
* @param array<string, string> $tags
*/
public function distribution(
string $key,
$value,
float $value,
?MetricsUnit $unit = null,
array $tags = [],
?int $timestamp = null,
Expand All @@ -86,12 +84,11 @@ public function distribution(
}

/**
* @param int|float $value
* @param array<string, string> $tags
*/
public function gauge(
string $key,
$value,
float $value,
?MetricsUnit $unit = null,
array $tags = [],
?int $timestamp = null,
Expand Down

0 comments on commit 7a51be0

Please sign in to comment.