Skip to content

Commit 7cad21c

Browse files
author
Robin Cawser
committed
Fix references
1 parent 01b6148 commit 7cad21c

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

EventListener/IdGeneratorListener.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ private function generateId($property, Vivait\StringGenerator $annotation)
6363
->setAlphabet($annotation->alphabet)
6464
->setLength($annotation->length);
6565

66-
$id = $$this->generator->generate();
66+
$id = $generator->generate();
6767

6868
if ($annotation->prefix) {
6969
$id = sprintf("%s%s%s", $annotation->prefix, $annotation->separator, $id);

Generator/StringGenerator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ public function generate()
2626
{
2727
$str = [];
2828
$alphaLength = strlen($this->alphabet) - 1;
29-
for ($i = 0; $i < $$this->length; $i++) {
29+
for ($i = 0; $i < $this->length; $i++) {
3030
$n = rand(0, $alphaLength);
3131
$str[] = $this->alphabet[$n];
3232
}

0 commit comments

Comments
 (0)