Skip to content

Commit 8c23a04

Browse files
committed
Make generator class a readonly
1 parent ed6e6c5 commit 8c23a04

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/Identifier/LaminasRandGenerator.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,12 @@
2424
/**
2525
* @author Oleg Kozlov <[email protected]>
2626
*/
27-
final class LaminasRandGenerator implements IdentifierGeneratorInterface
27+
final readonly class LaminasRandGenerator implements IdentifierGeneratorInterface
2828
{
2929
private const int MIN_LENGTH = 32;
3030

3131
public function __construct(
32-
private readonly int $length = 64,
32+
private int $length = 64,
3333
) {
3434
// @codeCoverageIgnoreStart
3535
if (!class_exists(Rand::class)) {

src/Identifier/UniqIdGenerator.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@
2323
*
2424
* @author Oleg Kozlov <[email protected]>
2525
*/
26-
final class UniqIdGenerator implements IdentifierGeneratorInterface
26+
final readonly class UniqIdGenerator implements IdentifierGeneratorInterface
2727
{
2828
public function __construct(
29-
private readonly string $prefix = '',
29+
private string $prefix = '',
3030
) {}
3131

3232
#[Override]

0 commit comments

Comments
 (0)