private function getEnabledResources($resources)
    {
        if (
            is_array($filters = config($configKey = 'health.resources.enabled'))
        ) {
            return collect($resources)->filter(function ($resource, $name) use (
                $filters
            ) {
                foreach ($filters as $filter) {
                    if (preg_match("|^$filter$|", $name)) {
                        return true;
                    }
                }

                return false;
            });
        }

        throw new DomainException("Invalid value for config('$configKey'')");
    }
private function getEnabledResources($resources)
    {
        if (
            is_array($filters = config($configKey = 'health.resources.enabled'))
        ) {
            return collect($resources)->filter(function ($resource, $name) use (
                $filters
            ) {
                foreach ($filters as $filter) {
                    if (preg_match("|^$filter$|", $name)) {
                        return true;
                    }
                }

                return false;
            });
        }

        throw new DomainException("Invalid value for config('$configKey'')");
    }
private function getEnabledResources ( $ resources ) { if ( is_array ( $ filters = config ( $ configKey = 'health.resources.enabled' ) ) ) { return collect ( $ resources ) -> filter ( function ( $ resource , $ name ) use ( $ filters ) { foreach ( $ filters as $ filter ) { if ( preg_match ( "|^$filter$|" , $ name ) ) { return true ; } } return false ; } ) ; } throw new DomainException ( "Invalid value for config('$configKey'')" ) ; }
Get enabled resources.

@param $resources
@return \Illuminate\Support\Collection
@throws \Exception
Get enabled resources .