sort valid ws-es in relative

This commit is contained in:
vaxerski 2022-12-08 21:24:55 +00:00
parent be6e1a33b1
commit 726732244a

View file

@ -286,6 +286,8 @@ int getWorkspaceIDFromString(const std::string& in, std::string& outName) {
validWSes.push_back(ws->m_iID);
}
std::sort(validWSes.begin(), validWSes.end());
// get the offset
remains = remains < 0 ? -((-remains) % validWSes.size()) : remains % validWSes.size();