Skip to content

Commit

Permalink
Fix 404 when there is an internal version of package (#27615)
Browse files Browse the repository at this point in the history
close #27601
The Docker registry has an internal version, which leads to 404
  • Loading branch information
lng2020 authored Oct 15, 2023
1 parent 4f6043f commit 7480aac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion routers/web/user/package.go
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@ func PackageSettingsPost(ctx *context.Context) {

redirectURL := ctx.Package.Owner.HomeLink() + "/-/packages"
// redirect to the package if there are still versions available
if has, _ := packages_model.ExistVersion(ctx, &packages_model.PackageSearchOptions{PackageID: ctx.Package.Descriptor.Package.ID}); has {
if has, _ := packages_model.ExistVersion(ctx, &packages_model.PackageSearchOptions{PackageID: ctx.Package.Descriptor.Package.ID, IsInternal: util.OptionalBoolFalse}); has {
redirectURL = ctx.Package.Descriptor.PackageWebLink()
}

Expand Down

0 comments on commit 7480aac

Please sign in to comment.