fix: pass all other requests to file search
This commit is contained in:
parent
6ea6895a36
commit
9bfc74833a
1 changed files with 1 additions and 4 deletions
|
@ -413,8 +413,7 @@ func DownloadPackageFile(ctx *context.Context) {
|
||||||
}
|
}
|
||||||
|
|
||||||
ctx.XML(http.StatusOK, nuget_module.GenerateNuspec(pkg))
|
ctx.XML(http.StatusOK, nuget_module.GenerateNuspec(pkg))
|
||||||
} else if filename == fmt.Sprintf("%s.%s.nupkg", packageName, packageVersion) {
|
} else {
|
||||||
|
|
||||||
s, u, pf, err := packages_service.GetFileStreamByPackageNameAndVersion(
|
s, u, pf, err := packages_service.GetFileStreamByPackageNameAndVersion(
|
||||||
ctx,
|
ctx,
|
||||||
&packages_service.PackageInfo{
|
&packages_service.PackageInfo{
|
||||||
|
@ -437,8 +436,6 @@ func DownloadPackageFile(ctx *context.Context) {
|
||||||
}
|
}
|
||||||
|
|
||||||
helper.ServePackageFile(ctx, s, u, pf)
|
helper.ServePackageFile(ctx, s, u, pf)
|
||||||
} else {
|
|
||||||
apiError(ctx, http.StatusInternalServerError, "Invalid filename")
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue