Fix dump and restore respository (#16698) (#16898)

* Fix dump and restore
* return different error message for get commit
* Fix missing delete release attachment when deleting repository
* Fix ci and add some comments

back port #16698

Co-authored-by: zeripath <art27@cantab.net>
This commit is contained in:
Lunny Xiao 2021-08-31 17:44:14 +08:00 committed by GitHub
parent 0274933c22
commit af1fd56d8a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 17 additions and 4 deletions

View file

@ -126,7 +126,7 @@ func getMergeCommit(pr *models.PullRequest) (*git.Commit, error) {
commit, err := gitRepo.GetCommit(mergeCommit[:40])
if err != nil {
return nil, fmt.Errorf("GetCommit: %v", err)
return nil, fmt.Errorf("GetMergeCommit[%v]: %v", mergeCommit[:40], err)
}
return commit, nil