Skip to content

Commit

Permalink
Fixed static analysis issue
Browse files Browse the repository at this point in the history
  • Loading branch information
jbtronics committed Mar 2, 2023
1 parent 4f43f10 commit 27de5ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Services/Attachments/AttachmentSubmitHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -444,7 +444,7 @@ private function parseFileSizeString(string $maxSize): int
if (ctype_digit((string) $maxSize)) {
return (int) $maxSize;
} elseif (preg_match('/^(\d++)('.implode('|', array_keys($factors)).')$/i', $maxSize, $matches)) {
return $matches[1] * $factors[$unit = strtolower($matches[2])];
return (((int) $matches[1]) * $factors[strtolower($matches[2])]);
} else {
throw new RuntimeException(sprintf('"%s" is not a valid maximum size.', $maxSize));
}
Expand Down

0 comments on commit 27de5ae

Please sign in to comment.