@@ -1,5 +1,5 @@ |
||
1 | 1 | <?php |
2 | -declare(strict_types=1); |
|
2 | +declare(strict_types = 1); |
|
3 | 3 | |
4 | 4 | namespace Ayesh\PHP_Timer; |
5 | 5 |
@@ -21,8 +21,7 @@ discard block |
||
21 | 21 | static::$timers[$key][0] = true; |
22 | 22 | static::$timers[$key][1] = static::getCurrentTime(); |
23 | 23 | } |
24 | - } |
|
25 | - else { |
|
24 | + } else { |
|
26 | 25 | static::$timers[$key] = [ |
27 | 26 | true, |
28 | 27 | static::getCurrentTime(), |
@@ -75,8 +74,7 @@ discard block |
||
75 | 74 | $ct = static::getCurrentTime(); |
76 | 75 | static::$timers[$key][0] = false; |
77 | 76 | static::$timers[$key][2] += $ct - static::$timers[$key][1]; |
78 | - } |
|
79 | - else { |
|
77 | + } else { |
|
80 | 78 | throw new \LogicException('Stopping timer when the given key timer was not initialized.'); |
81 | 79 | } |
82 | 80 | } |
@@ -79,7 +79,7 @@ |
||
79 | 79 | /** |
80 | 80 | * Pocesses the internal timer state to return the time elapsed. |
81 | 81 | * @param $value |
82 | - * @param $format |
|
82 | + * @param string $format |
|
83 | 83 | * @return mixed |
84 | 84 | */ |
85 | 85 | final protected static function processTimerValue($value, $format) { |