diff --git a/models/error.go b/models/error.go index be94d78891a..b2273f74c91 100644 --- a/models/error.go +++ b/models/error.go @@ -2003,7 +2003,7 @@ type ErrNotValidReviewRequest struct { // IsErrNotValidReviewRequest checks if an error is a ErrNotValidReviewRequest. func IsErrNotValidReviewRequest(err error) bool { - _, ok := err.(ErrReviewNotExist) + _, ok := err.(ErrNotValidReviewRequest) return ok }