Skip to content

Commit 1aab3e8

Browse files
Merge branch '6.4' into 7.2
* 6.4: - CS fixes
2 parents 3ef188d + 1e742d5 commit 1aab3e8

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

ProxyHelper.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ public static function generateLazyGhost(\ReflectionClass $class): string
7070
}
7171

7272
if ($flags & (\ReflectionProperty::IS_FINAL | \ReflectionProperty::IS_PRIVATE)) {
73-
throw new LogicException(sprintf('Cannot generate lazy ghost: property "%s::$%s" is final or private(set).', $class->name, $name));
73+
throw new LogicException(\sprintf('Cannot generate lazy ghost: property "%s::$%s" is final or private(set).', $class->name, $name));
7474
}
7575

7676
$p = $propertyScopes[$k][4] ?? Hydrator::$propertyScopes[$class->name][$k][4] = new \ReflectionProperty($scope, $name);
@@ -92,7 +92,7 @@ public static function generateLazyGhost(\ReflectionClass $class): string
9292
$arg = '$'.$method->getParameters()[0]->name;
9393
$hooks .= " set({$parameters}) { \$this->initializeLazyObject(); parent::\${$name}::set({$arg}); }\n";
9494
} else {
95-
throw new LogicException(sprintf('Cannot generate lazy ghost: hook "%s::%s()" is not supported.', $class->name, $method->name));
95+
throw new LogicException(\sprintf('Cannot generate lazy ghost: hook "%s::%s()" is not supported.', $class->name, $method->name));
9696
}
9797
}
9898

@@ -159,7 +159,7 @@ public static function generateLazyProxy(?\ReflectionClass $class, array $interf
159159
}
160160

161161
if ($flags & (\ReflectionProperty::IS_FINAL | \ReflectionProperty::IS_PRIVATE)) {
162-
throw new LogicException(sprintf('Cannot generate lazy proxy: property "%s::$%s" is final or private(set).', $class->name, $name));
162+
throw new LogicException(\sprintf('Cannot generate lazy proxy: property "%s::$%s" is final or private(set).', $class->name, $name));
163163
}
164164

165165
$p = $propertyScopes[$k][4] ?? Hydrator::$propertyScopes[$class->name][$k][4] = new \ReflectionProperty($scope, $name);
@@ -228,7 +228,7 @@ public static function generateLazyProxy(?\ReflectionClass $class, array $interf
228228
229229
EOPHP;
230230
} else {
231-
throw new LogicException(sprintf('Cannot generate lazy proxy: hook "%s::%s()" is not supported.', $class->name, $method->name));
231+
throw new LogicException(\sprintf('Cannot generate lazy proxy: hook "%s::%s()" is not supported.', $class->name, $method->name));
232232
}
233233
}
234234

Tests/LazyGhostTraitTest.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,7 @@ public function testPropertyHooksWithDefaultValue()
331331

332332
$this->assertSame(321, $object->backedIntWithDefault);
333333
$this->assertSame('321', $object->backedStringWithDefault);
334-
$this->assertSame(false, $object->backedBoolWithDefault);
334+
$this->assertFalse($object->backedBoolWithDefault);
335335
$this->assertTrue($initialized);
336336

337337
$initialized = false;
@@ -344,7 +344,7 @@ public function testPropertyHooksWithDefaultValue()
344344
$this->assertTrue($initialized);
345345
$this->assertSame(654, $object->backedIntWithDefault);
346346
$this->assertSame('654', $object->backedStringWithDefault);
347-
$this->assertSame(true, $object->backedBoolWithDefault);
347+
$this->assertTrue($object->backedBoolWithDefault);
348348
}
349349

350350
/**

0 commit comments

Comments
 (0)