Skip to content

Commit

Permalink
Avoid fetching partial versions when deleting packages as that requir…
Browse files Browse the repository at this point in the history
…es proper UoW managed versions
  • Loading branch information
Seldaek committed Oct 26, 2023
1 parent 2e6531f commit 239df1a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Controller/PackageController.php
Original file line number Diff line number Diff line change
Expand Up @@ -1537,7 +1537,7 @@ private function getPartialPackageWithVersions(Request $req, string $name): Pack
$repo = $this->getEM()->getRepository(Package::class);

try {
return $repo->getPartialPackageByNameWithVersions($name);
return $repo->getPackageByName($name);
} catch (NoResultException) {
if ('json' === $req->getRequestFormat()) {
return new JsonResponse(['status' => 'error', 'message' => 'Package not found'], 404);
Expand Down

0 comments on commit 239df1a

Please sign in to comment.