public function resolvePatches(PackageEvent $event)
    {
        // No need to resolve patches more than once.
        if ($this->patchesResolved) {
            return;
        }

        // Let each resolver discover patches and add them to the PatchCollection.
        /** @var ResolverInterface $resolver */
        foreach ($this->getPatchResolvers() as $resolver) {
            if (!in_array(get_class($resolver), $this->getConfig('disable-resolvers'), true)) {
                $resolver->resolve($this->patchCollection, $event);
            } else {
                if ($this->io->isVerbose()) {
                    $this->io->write('<info>  - Skipping resolver ' . get_class($resolver) . '</info>');
                }
            }
        }

        // Make sure we only do this once.
        $this->patchesResolved = true;
    }