Skip to content

Commit

Permalink
change no prefix found check to test file count and not file size
Browse files Browse the repository at this point in the history
  • Loading branch information
Akopti8 committed Jun 12, 2024
1 parent 5111774 commit 286bfe7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion blobstore/metadata.go
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ func (bh *BlobHandler) HandleGetSize(c echo.Context) error {
log.Error(errMsg.Error())
return c.JSON(http.StatusInternalServerError, errMsg.Error())
}
if totalSize == 0 {
if fileCount == 0 {
errMsg := fmt.Errorf("prefix %s not found", prefix)
log.Error(errMsg.Error())
return c.JSON(http.StatusNotFound, errMsg.Error())
Expand Down

0 comments on commit 286bfe7

Please sign in to comment.