mirror of
https://github.com/percona/percona-toolkit.git
synced 2026-05-07 01:00:05 +08:00
fmt
This commit is contained in:
@@ -142,7 +142,7 @@ func (self ExampleQuery) ExplainCmd() bson.D {
|
||||
for i := range cmd {
|
||||
// drop $db param as it is not supported in MongoDB 3.0
|
||||
if cmd[i].Name == "$db" {
|
||||
if len(cmd) - 1 == i {
|
||||
if len(cmd)-1 == i {
|
||||
cmd = cmd[:i]
|
||||
} else {
|
||||
cmd = append(cmd[:i], cmd[i+1:]...)
|
||||
|
||||
Reference in New Issue
Block a user