aboutsummaryrefslogtreecommitdiffstats
path: root/routers/api/packages/pypi/pypi.go
diff options
context:
space:
mode:
Diffstat (limited to 'routers/api/packages/pypi/pypi.go')
-rw-r--r--routers/api/packages/pypi/pypi.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/api/packages/pypi/pypi.go b/routers/api/packages/pypi/pypi.go
index 8c7f9bbf38..5718b1203b 100644
--- a/routers/api/packages/pypi/pypi.go
+++ b/routers/api/packages/pypi/pypi.go
@@ -177,7 +177,7 @@ func UploadPackageFile(ctx *context.Context) {
if err != nil {
switch err {
case packages_model.ErrDuplicatePackageFile:
- apiError(ctx, http.StatusBadRequest, err)
+ apiError(ctx, http.StatusConflict, err)
case packages_service.ErrQuotaTotalCount, packages_service.ErrQuotaTypeSize, packages_service.ErrQuotaTotalSize:
apiError(ctx, http.StatusForbidden, err)
default: