<?php

namespace Nimbusoft\Parrot\Plugin;

use Nimbusoft\Parrot\Parrot;
use League\Event\EventInterface;
use Nimbusoft\Parrot\Extension\AbstractPlugin;

class FilesPlugin extends AbstractPlugin
{
    public function register()
    {
        $this->parrot->listen('run', [$this, 'run'], Parrot::P_NORMAL);
    }

    public function run(EventInterface $event)
    {
        if ( ! isset($config['files'])) return;
    }
}

<?php

namespace Nimbusoft\Parrot\Plugin;

use Nimbusoft\Parrot\Parrot;
use League\Event\EventInterface;
use Nimbusoft\Parrot\Extension\AbstractPlugin;

class FilesPlugin extends AbstractPlugin
{
    public function register()
    {
        $this->parrot->listen('run', [$this, 'run'], Parrot::P_NORMAL);
    }

    public function run(EventInterface $event)
    {
        $config = $event->getConfig();

        if ( ! isset($config['files'])) return;
        if (isset($config['files']['adapter'])) $config['files'] = [$config['files']];
    }
}

Make sure files config is an array
Make sure files config is an array
