fix no config change bug with custom-http-errors
This commit is contained in:
parent
1959191cf3
commit
94a9a47225
1 changed files with 16 additions and 0 deletions
|
@ -449,6 +449,22 @@ func (l1 *Location) Equal(l2 *Location) bool {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if len(l1.CustomHTTPErrors) != len(l2.CustomHTTPErrors) {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
for _, code1 := range l1.CustomHTTPErrors {
|
||||||
|
found := false
|
||||||
|
for _, code2 := range l2.CustomHTTPErrors {
|
||||||
|
if code1 == code2 {
|
||||||
|
found = true
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if !found {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if !(&l1.ModSecurity).Equal(&l2.ModSecurity) {
|
if !(&l1.ModSecurity).Equal(&l2.ModSecurity) {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue