Skip to content

Commit

Permalink
revert to old status codes
Browse files Browse the repository at this point in the history
  • Loading branch information
Akopti8 committed May 10, 2024
1 parent 516ad82 commit 5a4d626
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion blobstore/delete.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ func (bh *BlobHandler) HandleDeletePrefix(c echo.Context) error {
if len(response.Contents) == 0 {
errMsg := fmt.Errorf("prefix %s is empty or does not exist", prefix)
log.Error(errMsg.Error())
return c.JSON(http.StatusBadRequest, errMsg.Error())
return c.JSON(http.StatusNotFound, errMsg.Error())
}

// This will recursively delete all objects with the specified prefix
Expand Down
2 changes: 1 addition & 1 deletion blobstore/presigned_url.go
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ func (bh *BlobHandler) HandleGenerateDownloadScript(c echo.Context) error {
if len(response.Contents) == 0 {
errMsg := fmt.Errorf("prefix %s is empty or does not exist", prefix)
log.Error(errMsg.Error())
return c.JSON(http.StatusBadRequest, errMsg.Error())
return c.JSON(http.StatusNotFound, errMsg.Error())
}
size, _, err := bh.GetSize(response)
if err != nil {
Expand Down

0 comments on commit 5a4d626

Please sign in to comment.