summaryrefslogtreecommitdiff
path: root/bot/src/localization
diff options
context:
space:
mode:
Diffstat (limited to 'bot/src/localization')
-rw-r--r--bot/src/localization/localization.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/bot/src/localization/localization.cpp b/bot/src/localization/localization.cpp
index b8659ea..fe7a02a 100644
--- a/bot/src/localization/localization.cpp
+++ b/bot/src/localization/localization.cpp
@@ -105,7 +105,7 @@ namespace bot {
const command::Request &request, const LineId &line_id,
const std::vector<std::string> &args) const {
std::optional<std::string> o_line = this->get_formatted_line(
- request.channel_preferences.get_locale(), line_id, args);
+ request.requester.channel_preferences.get_locale(), line_id, args);
if (!o_line.has_value()) {
return std::nullopt;
@@ -114,10 +114,11 @@ namespace bot {
std::string line = o_line.value();
std::map<std::string, std::string> token_map = {
- {"{sender.alias_name}", request.user.get_alias_name()},
- {"{source.alias_name}", request.channel.get_alias_name()},
+ {"{sender.alias_name}", request.requester.user.get_alias_name()},
+ {"{source.alias_name}", request.requester.channel.get_alias_name()},
{"{default.prefix}", DEFAULT_PREFIX},
- {"{channel.prefix}", request.channel_preferences.get_prefix()}};
+ {"{channel.prefix}",
+ request.requester.channel_preferences.get_prefix()}};
for (const auto &pair : token_map) {
int pos = line.find(pair.first);