Skip to content

Commit

Permalink
Update internal/locate/replica_selector_test.go
Browse files Browse the repository at this point in the history
Co-authored-by: you06 <[email protected]>
  • Loading branch information
crazycs520 and you06 authored Feb 23, 2024
1 parent 58d2dd2 commit abfcd1c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/locate/replica_selector_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ func (tp RegionErrorType) Valid(addr string, req *tikvrpc.Request) bool {
}
}
// replica-read.
if req.StaleRead == false && req.ReplicaRead == true {
if !req.StaleRead && req.ReplicaRead {
switch tp {
case NotLeaderErr, NotLeaderWithNewLeader1Err, NotLeaderWithNewLeader2Err, NotLeaderWithNewLeader3Err:
// NotLeaderErr will not return in replica read.
Expand Down

0 comments on commit abfcd1c

Please sign in to comment.