Skip to content

Commit 7d7ec98

Browse files
Copilotlisachenko
andcommitted
Fix proxy file path construction in ProxyClassReflectionHelper for PHP 8.4 compatibility
Co-authored-by: lisachenko <[email protected]>
1 parent 6430538 commit 7d7ec98

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tests/Go/PhpUnit/ProxyClassReflectionHelper.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,9 @@ public static function createReflectionClass(string $className, array $configura
4141

4242
$appDir = PathResolver::realpath($configuration['appDir']);
4343
$relativePath = str_replace($appDir . DIRECTORY_SEPARATOR, '', $originalClassFile);
44-
$classSuffix = str_replace('\\', DIRECTORY_SEPARATOR, $className) . '.php';
45-
$proxyRelativePath = $relativePath . DIRECTORY_SEPARATOR . $classSuffix;
46-
$proxyFileName = $configuration['cacheDir'] . '/_proxies/' . $proxyRelativePath;
44+
45+
// Use the same path construction logic as ClassWovenConstraint for consistency
46+
$proxyFileName = $configuration['cacheDir'] . '/_proxies' . DIRECTORY_SEPARATOR . $relativePath;
4747
$proxyFileContent = file_get_contents($proxyFileName);
4848

4949
if ($proxyFileContent === false) {

0 commit comments

Comments
 (0)