From 1cb835225b6b60d09232c8539d6377540e287621 Mon Sep 17 00:00:00 2001 From: James Williams Date: Mon, 17 Apr 2023 15:13:41 +0100 Subject: [PATCH] Only allow updating package being patched --- src/Composer/PatchAddCommand.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Composer/PatchAddCommand.php b/src/Composer/PatchAddCommand.php index d2b54f5..97017df 100644 --- a/src/Composer/PatchAddCommand.php +++ b/src/Composer/PatchAddCommand.php @@ -165,7 +165,7 @@ protected function execute(InputInterface $input, OutputInterface $output) { // Only update the current package ->setUpdateAllowList([$package]) // Don't update the dependencies of the patched package. - ->setUpdateAllowTransitiveDependencies(Request::UPDATE_LISTED_WITH_TRANSITIVE_DEPS_NO_ROOT_REQUIRE) + ->setUpdateAllowTransitiveDependencies(Request::UPDATE_ONLY_LISTED) // Patches are always considered to be applied in "dev mode". // This is also required to prevent composer from removing all installed // dev dependencies.