Skip to content

Commit

Permalink
Replace TextLanguage with Locale
Browse files Browse the repository at this point in the history
  • Loading branch information
Robi9 committed May 21, 2024
1 parent d81d3df commit 8d2ff1e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion core/handlers/msg_created.go
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ func handleMsgCreated(ctx context.Context, rt *runtime.Runtime, tx *sqlx.Tx, oa
languageCode = ""
}

event.Msg.TextLanguage = envs.Language(languageCode)
event.Msg.Locale_ = envs.Locale(languageCode)
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions core/models/msgs.go
Original file line number Diff line number Diff line change
Expand Up @@ -439,8 +439,8 @@ func buildMsgMetadata(m *flows.MsgOut) map[string]interface{} {
if m.Topic() != flows.NilMsgTopic {
metadata["topic"] = string(m.Topic())
}
if m.TextLanguage != "" {
metadata["text_language"] = m.TextLanguage
if m.Locale() != "" {
metadata["locale"] = m.Locale_
}
return metadata
}
Expand Down

0 comments on commit 8d2ff1e

Please sign in to comment.