Skip to content

Commit

Permalink
Use equal in args (#2170)
Browse files Browse the repository at this point in the history
Signed-off-by: sayedppqq <sayed@appscode.com>
  • Loading branch information
sayedppqq authored Aug 28, 2024
1 parent c5810d8 commit ffc259a
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions pkg/backup.go
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,6 @@ func (opt *mongoOptions) backupMongoDB(targetRef api_v1beta1.TargetRef) (*restic
if !ok {
crt, ok := tlsSecret.Data[core.TLSCertKey]
if !ok {
fmt.Println("here.........................")
return nil, errors.Wrap(err, "unable to retrieve tls.crt from secret.")
}
key, ok := tlsSecret.Data[core.TLSPrivateKeyKey]
Expand Down Expand Up @@ -397,7 +396,7 @@ func (opt *mongoOptions) backupMongoDB(targetRef api_v1beta1.TargetRef) (*restic
dumpCreds = append(dumpCreds, []interface{}{
fmt.Sprintf("--username=%s", username),
fmt.Sprintf("--password=%s", authSecret.Data[MongoPasswordKey]),
"--authenticationDatabase", opt.authenticationDatabase,
fmt.Sprintf("--authenticationDatabase=%s", opt.authenticationDatabase),
}...)

} else {
Expand All @@ -414,7 +413,7 @@ func (opt *mongoOptions) backupMongoDB(targetRef api_v1beta1.TargetRef) (*restic
dumpCreds = append(dumpCreds, []interface{}{
fmt.Sprintf("--username=%s", username),
fmt.Sprintf("--password=%s", authSecret.Data[MongoPasswordKey]),
"--authenticationDatabase", opt.authenticationDatabase,
fmt.Sprintf("--authenticationDatabase=%s", opt.authenticationDatabase),
}...)
}

Expand Down

0 comments on commit ffc259a

Please sign in to comment.