Skip to content

Commit

Permalink
fix bug in reverse if
Browse files Browse the repository at this point in the history
Signed-off-by: Tim Vaillancourt <[email protected]>
  • Loading branch information
timvaillancourt committed Mar 10, 2025
1 parent 995b3c6 commit 1b3b275
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions go/vt/vtorc/logic/tablet_discovery.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,16 +67,12 @@ var (
)

func getTabletsWatchedByCell() map[string]int64 {
tabletsWatchedByCell := make(map[string]int64)
tabletsByCell, err := inst.ReadTabletCountsByCell()
if err == nil {
tabletsCountsByCell, err := inst.ReadTabletCountsByCell()
if err != nil {
log.Errorf("Failed to read tablet counts by cell: %+v", err)
return tabletsWatchedByCell
}
for cell, tabletCount := range tabletsByCell {
tabletsWatchedByCell[cell] = tabletCount
return tabletsCountsByCell
}
return tabletsWatchedByCell
return tabletsCountsByCell
}

// RegisterFlags registers the flags required by VTOrc
Expand Down

0 comments on commit 1b3b275

Please sign in to comment.