array_filter

Supported Versions: PHP 4 >= 4.0.6, PHP 5, PHP 7, PHP 8
Filters elements of an array using a callback function
<?php array_filter(array $array, ?callable $callback = null, int $mode = 0): array
<?php     {



        return array_filter($data, function ($value, $key) {

            if ($key === 'app') {

                return ! $value instanceof Application;

            }



            return $key !== '__env';

        }, ARRAY_FILTER_USE_BOTH);

    }



    public function getCompiledViewData($compiledPath): array