Skip to content

Commit

Permalink
ScalarBeanPropertyDescriptor: Fix variable for resource null check
Browse files Browse the repository at this point in the history
  • Loading branch information
homersimpsons committed Sep 4, 2020
1 parent 1a056bc commit 4eed2f7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Utils/ScalarBeanPropertyDescriptor.php
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ public function getGetterSetterCode(): array
if ($normalizedType === 'resource') {
$checkNullable = '';
if ($isNullable) {
$checkNullable = sprintf('$%s !== null && ', $this->column->getName());
$checkNullable = sprintf('$%s !== null && ', $variableName);
}
$resourceTypeCheck .= <<<EOF
if (%s!\is_resource($%s)) {
Expand Down

0 comments on commit 4eed2f7

Please sign in to comment.