| Conditions | 2 |
| Paths | 2 |
| Total Lines | 9 |
| Code Lines | 4 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 5 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php |
||
| 33 | 6 | public function incrementBy(float $value, array $labels = []): Incrementable |
|
| 34 | { |
||
| 35 | 6 | if ($value < 0) { |
|
| 36 | 1 | throw new PrometheusException('Counters can only be incremented by non-negative amounts.'); |
|
| 37 | } |
||
| 38 | |||
| 39 | 5 | static::$storage->increment($this, $value, $labels); |
|
| 40 | |||
| 41 | 5 | return $this; |
|
| 42 | } |
||
| 44 |