Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Use more const ref in loops

parent f052fc07
......@@ -235,7 +235,7 @@ void ActivitiesProtocol::listDir(const QUrl &url)
uds.fastInsert(KIO::UDSEntry::UDS_TARGET_URL, QStringLiteral("activities:/") + activities.currentActivity());
udslist << uds;
for (const auto activity: activities.activities()) {
for (const auto& activity: activities.activities()) {
udslist << d->activityEntry(activity);
}
......
......@@ -265,7 +265,7 @@ QSqlQuery Database::execQueries(const QStringList &queries) const
{
QSqlQuery result;
for (const auto query: queries) {
for (const auto& query: queries) {
result = execQuery(query);
}
......
......@@ -150,7 +150,7 @@ void FileItemLinkingPlugin::Private::setActions(const ActionList &actions)
action->deleteLater();
}
for (auto actionInfo: actions) {
for (const auto& actionInfo: actions) {
if (actionInfo.icon != "-") {
auto action = new QAction(nullptr);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment