Skip to content

Commit

Permalink
Change casing of server options
Browse files Browse the repository at this point in the history
  • Loading branch information
neekolas committed Oct 24, 2023
1 parent da11034 commit e09fca1
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions cmd/xmtpd/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,8 @@ func main() {
return
}

if options.CreateMlsMigration != "" && options.MlsStore.DbConnectionString != "" {
if err := server.CreateMlsMigration(options.CreateMlsMigration, options.MlsStore.DbConnectionString, options.WaitForDB, options.MlsStore.ReadTimeout, options.MlsStore.WriteTimeout, options.Store.MaxOpenConns); err != nil {
if options.CreateMlsMigration != "" && options.MLSStore.DbConnectionString != "" {
if err := server.CreateMlsMigration(options.CreateMlsMigration, options.MLSStore.DbConnectionString, options.WaitForDB, options.MLSStore.ReadTimeout, options.MLSStore.WriteTimeout, options.Store.MaxOpenConns); err != nil {
log.Fatal("creating authz db migration", zap.Error(err))
}
return
Expand Down
2 changes: 1 addition & 1 deletion pkg/server/options.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,6 @@ type Options struct {
Metrics MetricsOptions `group:"Metrics Options"`
Tracing TracingOptions `group:"DD APM Tracing Options"`
Profiling ProfilingOptions `group:"DD APM Profiling Options" namespace:"profiling"`
MlsStore mlsstore.StoreOptions `group:"MLS Options" namespace:"mls-store"`
MLSStore mlsstore.StoreOptions `group:"MLS Options" namespace:"mls-store"`
MlsValidation mlsvalidate.MlsValidationOptions `group:"MLS Validation Options" namespace:"mls-validation"`
}
4 changes: 2 additions & 2 deletions pkg/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -231,8 +231,8 @@ func New(ctx context.Context, log *zap.Logger, options Options) (*Server, error)

var MLSStore mlsstore.MlsStore

if options.MlsStore.DbConnectionString != "" {
mlsDb, err := createBunDB(options.MlsStore.DbConnectionString, options.WaitForDB, options.MlsStore.ReadTimeout, options.MlsStore.WriteTimeout, options.MlsStore.MaxOpenConns)
if options.MLSStore.DbConnectionString != "" {
mlsDb, err := createBunDB(options.MLSStore.DbConnectionString, options.WaitForDB, options.MLSStore.ReadTimeout, options.MLSStore.WriteTimeout, options.MLSStore.MaxOpenConns)
if err != nil {
return nil, errors.Wrap(err, "creating mls db")
}
Expand Down

0 comments on commit e09fca1

Please sign in to comment.