Fix stringTools join function.

This commit is contained in:
Matthieu Gautier
2019-09-17 16:19:50 +02:00
parent f4e9148b1d
commit 2f4636e2df
3 changed files with 48 additions and 3 deletions

View File

@@ -303,10 +303,10 @@ std::string kiwix::join(const std::vector<std::string>& list, const std::string&
std::stringstream ss;
bool first = true;
for (auto& s:list) {
if (first) {
if (!first) {
ss << sep;
first = false;
}
first = false;
ss << s;
}
return ss.str();