mirror of
https://github.com/project-zot/zot.git
synced 2024-12-30 22:34:13 -05:00
commit
131e19c26d
1 changed files with 2 additions and 0 deletions
|
@ -194,6 +194,7 @@ func (rh *RouteHandler) GetManifest(ginCtx *gin.Context) {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
switch err {
|
switch err {
|
||||||
case errors.ErrRepoNotFound:
|
case errors.ErrRepoNotFound:
|
||||||
|
ginCtx.JSON(http.StatusNotFound, NewError(NAME_UNKNOWN, map[string]string{"name": name}))
|
||||||
case errors.ErrRepoBadVersion:
|
case errors.ErrRepoBadVersion:
|
||||||
ginCtx.JSON(http.StatusNotFound, NewError(NAME_UNKNOWN, map[string]string{"name": name}))
|
ginCtx.JSON(http.StatusNotFound, NewError(NAME_UNKNOWN, map[string]string{"name": name}))
|
||||||
case errors.ErrManifestNotFound:
|
case errors.ErrManifestNotFound:
|
||||||
|
@ -518,6 +519,7 @@ func (rh *RouteHandler) GetBlobUpload(ginCtx *gin.Context) {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
switch err {
|
switch err {
|
||||||
case errors.ErrBadUploadRange:
|
case errors.ErrBadUploadRange:
|
||||||
|
ginCtx.JSON(http.StatusBadRequest, NewError(BLOB_UPLOAD_INVALID, map[string]string{"uuid": uuid}))
|
||||||
case errors.ErrBadBlobDigest:
|
case errors.ErrBadBlobDigest:
|
||||||
ginCtx.JSON(http.StatusBadRequest, NewError(BLOB_UPLOAD_INVALID, map[string]string{"uuid": uuid}))
|
ginCtx.JSON(http.StatusBadRequest, NewError(BLOB_UPLOAD_INVALID, map[string]string{"uuid": uuid}))
|
||||||
case errors.ErrRepoNotFound:
|
case errors.ErrRepoNotFound:
|
||||||
|
|
Loading…
Reference in a new issue