Skip to content

Commit 3c17638

Browse files
6543lunny
andauthored
Update models/git/protected_branch.go
Co-authored-by: Lunny Xiao <[email protected]>
1 parent c8b35fd commit 3c17638

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

models/git/protected_branch.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,8 @@ func IsRuleNameSpecial(ruleName string) bool {
8383
}
8484

8585
func (protectBranch *ProtectedBranch) loadGlob() {
86-
if protectBranch.globRule == nil && !protectBranch.isPlainName {
86+
if protectBranch.isPlainName || protectBranch.globRule != nil {
87+
return
8788
// detect if it is not glob
8889
if !IsRuleNameSpecial(protectBranch.RuleName) {
8990
protectBranch.isPlainName = true

0 commit comments

Comments
 (0)