Fix Qt6 building (#4393)

This commit is contained in:
pajlada
2023-02-19 20:19:18 +01:00
committed by GitHub
parent d3499e814e
commit c95a65c153
22 changed files with 114 additions and 37 deletions
@@ -3191,7 +3191,8 @@ QString CommandController::execCommand(const QString &textNoEmoji,
}
}
auto maxSpaces = std::min(this->maxSpaces_, words.length() - 1);
// We have checks to ensure words cannot be empty, so this can never wrap around
auto maxSpaces = std::min(this->maxSpaces_, (qsizetype)words.length() - 1);
for (int i = 0; i < maxSpaces; ++i)
{
commandName += ' ' + words[i + 1];