mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-12 08:27:32 +00:00
fix: custom mail texts (#2101)
* fix: custom mail texts * fix: custom mail texts * disable cache * enable cache again * disable cache again * comment
This commit is contained in:
@@ -398,18 +398,18 @@ func (n *Notification) getTranslatorWithOrgTexts(orgID, textType string) (*i18n.
|
||||
return nil, err
|
||||
}
|
||||
allCustomTexts, err := n.view.CustomTextsByAggregateIDAndTemplate(domain.IAMID, textType)
|
||||
if err == nil {
|
||||
if err != nil {
|
||||
return translator, nil
|
||||
}
|
||||
customTexts, err := n.view.CustomTextsByAggregateIDAndTemplate(orgID, textType)
|
||||
if err == nil {
|
||||
if err != nil {
|
||||
return translator, nil
|
||||
}
|
||||
allCustomTexts = append(allCustomTexts, customTexts...)
|
||||
|
||||
for _, text := range allCustomTexts {
|
||||
msg := i18n.Message{
|
||||
ID: text.Key,
|
||||
ID: text.Template + "." + text.Key,
|
||||
Text: text.Text,
|
||||
}
|
||||
translator.AddMessages(language.Make(text.Language), msg)
|
||||
|
Reference in New Issue
Block a user