Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
limingxinleo committed Feb 25, 2022
1 parent 7505d3a commit 4bf0af5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/DragVerifier.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,11 @@ public function __construct(
?int $color = null,
) {
if ($hollowedImage === null) {
$this->hollowedImage = $this->createHollowedImage();
$hollowedImage = $this->createHollowedImage();
}

$this->color = $color ?? imagecolorat($this->hollowedImage, 0, 0);
$this->hollowedImage = $hollowedImage;
$this->color = $color ?? imagecolorat($hollowedImage, 0, 0);
}

public function generate(): DragCode
Expand Down

0 comments on commit 4bf0af5

Please sign in to comment.