Skip to content

Commit d22e654

Browse files
authored
Use the reflection method
1 parent c04d78e commit d22e654

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

inc/Action/AbstractAction.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,7 @@ public function __construct($actionname = '')
2828
$this->actionname = $actionname;
2929
} else {
3030
// As of PHP 8 this seems to be the fastest way to get the name:
31-
$n = explode('\\', get_class($this));
32-
$this->actionname = strtolower(array_pop($n));
31+
$this->actionname = strtolower((new \ReflectionClass($this))->getShortName());
3332
}
3433
}
3534

0 commit comments

Comments
 (0)