diff options
Diffstat (limited to 'routers/api/packages/cran/cran.go')
-rw-r--r-- | routers/api/packages/cran/cran.go | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/routers/api/packages/cran/cran.go b/routers/api/packages/cran/cran.go index f1d616724a..8a20072cb6 100644 --- a/routers/api/packages/cran/cran.go +++ b/routers/api/packages/cran/cran.go @@ -28,18 +28,18 @@ func apiError(ctx *context.Context, status int, obj any) { } func EnumerateSourcePackages(ctx *context.Context) { - enumeratePackages(ctx, ctx.Params("format"), &cran_model.SearchOptions{ + enumeratePackages(ctx, ctx.PathParam("format"), &cran_model.SearchOptions{ OwnerID: ctx.Package.Owner.ID, FileType: cran_module.TypeSource, }) } func EnumerateBinaryPackages(ctx *context.Context) { - enumeratePackages(ctx, ctx.Params("format"), &cran_model.SearchOptions{ + enumeratePackages(ctx, ctx.PathParam("format"), &cran_model.SearchOptions{ OwnerID: ctx.Package.Owner.ID, FileType: cran_module.TypeBinary, - Platform: ctx.Params("platform"), - RVersion: ctx.Params("rversion"), + Platform: ctx.PathParam("platform"), + RVersion: ctx.PathParam("rversion"), }) } @@ -225,7 +225,7 @@ func DownloadSourcePackageFile(ctx *context.Context) { downloadPackageFile(ctx, &cran_model.SearchOptions{ OwnerID: ctx.Package.Owner.ID, FileType: cran_module.TypeSource, - Filename: ctx.Params("filename"), + Filename: ctx.PathParam("filename"), }) } @@ -233,9 +233,9 @@ func DownloadBinaryPackageFile(ctx *context.Context) { downloadPackageFile(ctx, &cran_model.SearchOptions{ OwnerID: ctx.Package.Owner.ID, FileType: cran_module.TypeBinary, - Platform: ctx.Params("platform"), - RVersion: ctx.Params("rversion"), - Filename: ctx.Params("filename"), + Platform: ctx.PathParam("platform"), + RVersion: ctx.PathParam("rversion"), + Filename: ctx.PathParam("filename"), }) } |