mirror of
https://github.com/delight-im/PHP-Auth.git
synced 2025-07-30 21:00:13 +02:00
Make use of new method 'getMap' from class 'Role' in 'tests'
This commit is contained in:
@@ -923,11 +923,9 @@ function showConfirmEmailForm() {
|
||||
}
|
||||
|
||||
function createRolesOptions() {
|
||||
$roleReflection = new ReflectionClass(\Delight\Auth\Role::class);
|
||||
|
||||
$out = '';
|
||||
|
||||
foreach ($roleReflection->getConstants() as $roleName => $roleValue) {
|
||||
foreach (\Delight\Auth\Role::getMap() as $roleValue => $roleName) {
|
||||
$out .= '<option value="' . $roleValue . '">' . $roleName . '</option>';
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user