Improved typing and phpdoc type annotations

This commit is contained in:
Jan Böhmer 2023-06-18 15:37:42 +02:00
parent 3817ba774d
commit b7c8ca2a48
39 changed files with 189 additions and 129 deletions

View file

@ -57,7 +57,11 @@ class LogDiffFormatter
]);
}
private function diffNumeric($old_data, $new_data): string
/**
* @param numeric $old_data
* @param numeric $new_data
*/
private function diffNumeric(int|float|string $old_data, int|float|string $new_data): string
{
if ((!is_numeric($old_data)) || (!is_numeric($new_data))) {
throw new \InvalidArgumentException('The given data is not numeric.');