Skip to content
This repository was archived by the owner on Jul 10, 2023. It is now read-only.

Commit 729119c

Browse files
authored
Use ReflectionClass to determine Controller inheritance
Issue: If a class extends another class that extends Sober\Controller\Controller it would be excluded.
1 parent 9599675 commit 729119c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Loader.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ protected function setClassesToRun()
100100
}
101101

102102
// Exclude non-Controller classes
103-
if (!Utils::doesFileContain($filename, 'extends Controller')) {
103+
if (!$reflection->isSubclassOf('Sober\Controller\Controller')) {
104104
continue;
105105
}
106106

0 commit comments

Comments
 (0)