protected function assertFile(string $file, array $options): bool
    {
        if (is_file($file) && is_readable($file)) {
            return true;
        }

        if (!(bool)($options['optional'] ?? false)) {
            throw new LoadException("Config file '$file' doesn't exist or is not readable");
        }

        return false;
    }
protected function assertFile(string $file, array $options): bool
    {
        if (is_file($file) && is_readable($file)) {
            return true;
        }

        if (!(bool)($options['optional'] ?? false)) {
            throw new LoadException("Config file '$file' doesn't exist or is not readable");
        }

        return false;
    }
protected function assertFile ( string $ file , array $ options ) : bool { if ( is_file ( $ file ) && is_readable ( $ file ) ) { return true ; } if ( ! ( bool ) ( $ options [ 'optional' ] ?? false ) ) { throw new LoadException ( "Config file '$file' doesn't exist or is not readable" ) ; } return false ; }
Assert the file exists

@param string $file
@param array  $options
@return bool
@throws NotFoundException
Assert the file exists