better message formatting
Some checks failed
ci/woodpecker/push/billing_fees Pipeline was successful
ci/woodpecker/push/bff Pipeline was successful
ci/woodpecker/push/db Pipeline was successful
ci/woodpecker/push/chain_gateway Pipeline was successful
ci/woodpecker/push/fx_ingestor Pipeline was successful
ci/woodpecker/push/fx_oracle Pipeline was successful
ci/woodpecker/push/frontend Pipeline was successful
ci/woodpecker/push/payments_orchestrator Pipeline was successful
ci/woodpecker/push/bump_version Pipeline failed
ci/woodpecker/push/nats Pipeline was successful
ci/woodpecker/push/ledger Pipeline was successful
ci/woodpecker/push/notification Pipeline was successful
Some checks failed
ci/woodpecker/push/billing_fees Pipeline was successful
ci/woodpecker/push/bff Pipeline was successful
ci/woodpecker/push/db Pipeline was successful
ci/woodpecker/push/chain_gateway Pipeline was successful
ci/woodpecker/push/fx_ingestor Pipeline was successful
ci/woodpecker/push/fx_oracle Pipeline was successful
ci/woodpecker/push/frontend Pipeline was successful
ci/woodpecker/push/payments_orchestrator Pipeline was successful
ci/woodpecker/push/bump_version Pipeline failed
ci/woodpecker/push/nats Pipeline was successful
ci/woodpecker/push/ledger Pipeline was successful
ci/woodpecker/push/notification Pipeline was successful
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package mail
|
||||
|
||||
import (
|
||||
"github.com/mitchellh/mapstructure"
|
||||
"github.com/tech/sendico/notification/interface/api/localizer"
|
||||
notification "github.com/tech/sendico/notification/interface/services/notification/config"
|
||||
mi "github.com/tech/sendico/notification/internal/server/notificationimp/mail/internal"
|
||||
@@ -9,7 +10,6 @@ import (
|
||||
"github.com/tech/sendico/pkg/merrors"
|
||||
"github.com/tech/sendico/pkg/messaging"
|
||||
"github.com/tech/sendico/pkg/mlogger"
|
||||
"github.com/mitchellh/mapstructure"
|
||||
"go.uber.org/zap"
|
||||
)
|
||||
|
||||
@@ -22,7 +22,7 @@ type Config = notification.Config
|
||||
|
||||
func createMailClient(logger mlogger.Logger, producer messaging.Producer, l localizer.Localizer, dp domainprovider.DomainProvider, config *Config) (Client, error) {
|
||||
if len(config.Driver) == 0 {
|
||||
return nil, merrors.InvalidArgument("Mail driver name must be provided")
|
||||
return nil, merrors.InvalidArgument("Mail driver name must be provided", "config.driver")
|
||||
}
|
||||
logger.Info("Connecting mail client...", zap.String("driver", config.Driver))
|
||||
if config.Driver == "dummy" {
|
||||
@@ -45,7 +45,7 @@ func createMailClient(logger mlogger.Logger, producer messaging.Producer, l loca
|
||||
|
||||
return mi.NewClient(logger, l, dp, &gsmconfing), nil
|
||||
}
|
||||
return nil, merrors.InvalidArgument("Unkwnown mail driver: " + config.Driver)
|
||||
return nil, merrors.InvalidArgument("Unkwnown mail driver: "+config.Driver, "config.driver")
|
||||
}
|
||||
|
||||
func CreateMailClient(logger mlogger.Logger, sender string, producer messaging.Producer, l localizer.Localizer, dp domainprovider.DomainProvider, config *Config) (Client, error) {
|
||||
|
||||
Reference in New Issue
Block a user