lk-students/app/Helpers/AllfieldsUserHelper.php

17 lines
300 B
PHP
Raw Permalink Normal View History

2024-07-12 12:45:23 +03:00
<?php
namespace App\Helpers;
use App\Enums\UserFields;
class AllfieldsUserHelper
{
public static function get()
{
return array_reduce(UserFields::cases(), function ($carry, $item) {
$carry[$item->name] = $item->value;
return $carry;
}, []);
}
}