summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/xmpp/biboumi_adhoc_commands.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/xmpp/biboumi_adhoc_commands.cpp b/src/xmpp/biboumi_adhoc_commands.cpp
index d9162d7..19e6a71 100644
--- a/src/xmpp/biboumi_adhoc_commands.cpp
+++ b/src/xmpp/biboumi_adhoc_commands.cpp
@@ -264,8 +264,7 @@ void ConfigureIrcServerStep2(XmppComponent*, AdhocSession& session, XmlNode& com
{
auto username = value->get_inner();
// The username must not contain spaces
- std::replace(&username[0], &username[username.size() - 1],
- ' ', '_');
+ std::replace(username.begin(), username.end(), ' ', '_');
options.username = username;
}