Supported Versions: PHP 4, PHP 5, PHP 7, PHP 8
Finds whether a variable is an array
<?php is_array(mixed $value): bool
<?php             ->explode("\n")

            ->filter()

            ->each(function ($output) {

                if (! is_array($debug = json_decode($output, true))) {

                    return $this->info($output);

                }
<?php                     return $this->info($output);

                }



                if (is_array($stream = json_decode($debug['msg'], true))) {

                    return $this->handleStream($stream);

                }
<?php         Str::of($server->getIncrementalOutput())

            ->explode("\n")

            ->filter()

            ->each(fn ($output) => is_array($stream = json_decode($output, true))

                ? $this->handleStream($stream)

                : $this->info($output)

            );
<?php             ->filter()

            ->groupBy(fn ($output) => $output)

            ->each(function ($group) {

                is_array($stream = json_decode($output = $group->first(), true)) && isset($stream['type'])

                    ? $this->handleStream($stream)

                    : $this->raw($output);

            });