Skip to content

Commit

Permalink
Initial implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
antonkomarev committed Oct 14, 2023
1 parent b35a68d commit dc65109
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/FontList.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,15 @@ public static function of(
): self {
foreach ($fontList as $font) {
if (!($font instanceof Font)) {
throw new \InvalidArgumentException('Cannot instantiate FontList with ');
throw new \InvalidArgumentException(
'Cannot instantiate FontList with type `' . get_class($font) . '`'
);
}
}

return new self($fontList);
return new self(
$fontList,
);
}

public function getById(
Expand Down

0 comments on commit dc65109

Please sign in to comment.