Skip to content

Commit

Permalink
use equal in args
Browse files Browse the repository at this point in the history
Signed-off-by: sayedppqq <[email protected]>
  • Loading branch information
sayedppqq committed Aug 28, 2024
1 parent c5810d8 commit 8999d19
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 8999d19

Please sign in to comment.