@@ -794,7 +794,7 @@ func DismissPullReview(ctx *context.APIContext, opts api.DismissPullReviewOption
794
794
// "$ref": "#/responses/forbidden"
795
795
// "422":
796
796
// "$ref": "#/responses/validationError"
797
- disMissReview (ctx , true )
797
+ disMissReview (ctx , opts . Message , true )
798
798
}
799
799
800
800
// UnDismissPullReview cancel to dismiss a review for a pull request
@@ -834,10 +834,10 @@ func UnDismissPullReview(ctx *context.APIContext) {
834
834
// "$ref": "#/responses/forbidden"
835
835
// "422":
836
836
// "$ref": "#/responses/validationError"
837
- disMissReview (ctx , false )
837
+ disMissReview (ctx , "" , false )
838
838
}
839
839
840
- func disMissReview (ctx * context.APIContext , isDismiss bool ) {
840
+ func disMissReview (ctx * context.APIContext , msg string , isDismiss bool ) {
841
841
if ! ctx .Repo .IsAdmin () {
842
842
ctx .Error (http .StatusForbidden , "" , "Must be repo admin" )
843
843
return
@@ -857,7 +857,7 @@ func disMissReview(ctx *context.APIContext, isDismiss bool) {
857
857
return
858
858
}
859
859
860
- _ , err := pull_service .DismissReview (review .ID , opts . Message , ctx .User , isDismiss )
860
+ _ , err := pull_service .DismissReview (review .ID , msg , ctx .User , isDismiss )
861
861
if err != nil {
862
862
ctx .Error (http .StatusInternalServerError , "pull_service.DismissReview" , err )
863
863
return
0 commit comments