We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6e6936d commit f09cdb2Copy full SHA for f09cdb2
models/branches.go
@@ -153,7 +153,7 @@ func (protectBranch *ProtectedBranch) HasEnoughApprovals(pr *PullRequest) bool {
153
154
// GetGrantedApprovalsCount returns the number of granted approvals for pr. A granted approval must be authored by a user in an approval whitelist.
155
func (protectBranch *ProtectedBranch) GetGrantedApprovalsCount(pr *PullRequest) int64 {
156
- approvals, err := x.Where("issue_id = ?", pr.Issue.ID).
+ approvals, err := x.Where("issue_id = ?", pr.IssueID).
157
And("type = ?", ReviewTypeApprove).
158
And("official = ?", true).
159
Count(new(Review))
0 commit comments