private function validateRoutesSectionInExtra(array $extra)
    {
        if (!isset($extra['phplist/core'])) {
            return;
        }
        $this->validatePhpListSectionInExtra($extra);

        if (!isset($extra['phplist/core']['routes'])) {
            return;
        }
        if (!is_array($extra['phplist/core']['routes'])) {
            throw new \InvalidArgumentException(
                'The extras.phplist/core.routes section in the composer.json must be an array.',
                1506429004
            );
        }

        /** @var array $bundleExtras */
        $bundleExtras = $extra['phplist/core']['routes'];
        foreach ($bundleExtras as $routeName => $routeConfiguration) {
            if (!is_array($routeConfiguration)) {
                throw new \InvalidArgumentException(
                    'The extras.phplist/core.routes. ' . $routeName .
                    '" section in the composer.json must be an array.',
                    1506429860
                );
            }
        }
    }