diff --git a/services/context/repo.go b/services/context/repo.go index afc6de9b1666d..802978ed08e93 100644 --- a/services/context/repo.go +++ b/services/context/repo.go @@ -143,7 +143,7 @@ func PrepareCommitFormOptions(ctx *Context, doer *user_model.User, targetRepo *r wontSignReason := "" if asymkey_service.IsErrWontSign(err) { wontSignReason = string(err.(*asymkey_service.ErrWontSign).Reason) - } else if err != nil { + } else if err != nil && !errors.Is(err, util.ErrNotExist) { return nil, err }