Replace deprecated .toSet()

This commit is contained in:
Dale Glass 2022-06-05 13:05:49 +02:00
parent aefb6860e6
commit a7f6fed937
2 changed files with 3 additions and 3 deletions

View file

@ -237,7 +237,7 @@ void AvatarDoctor::startDiagnosing() {
jointValues << jointVariant.toString();
}
const auto& uniqueJointValues = jointValues.toSet();
const auto& uniqueJointValues = QSet<QString>(jointValues.begin(), jointValues.end());
for (const auto& jointName: uniqueJointValues) {
if (jointValues.count(jointName) > 1) {
addError(tr("%1 is mapped multiple times.").arg(jointName), "mapped-multiple-times");

View file

@ -24,11 +24,11 @@
#include "ScriptEngines.h"
#include "ScriptCache.h"
BatchLoader::BatchLoader(const QList<QUrl>& urls)
BatchLoader::BatchLoader(const QList<QUrl>& urls)
: QObject(),
_started(false),
_finished(false),
_urls(urls.toSet()),
_urls(QSet<QUrl>(urls.begin(), urls.end())),
_data(),
_status() {
qRegisterMetaType<QMap<QUrl, QString>>("QMap<QUrl, QString>");