Commit 9ddbf11f authored by Laurent Montel's avatar Laurent Montel 😁

Port to for(..:..)

parent 1e3909d7
......@@ -176,7 +176,7 @@ void NotificationManager::emitPendingNotifications()
// so that we can work with return value of notify()
for (const auto &notification : qAsConst(mNotifications)) {
QVector<QByteArray> listeners;
Q_FOREACH (NotificationSubscriber *subscriber, mSubscribers) {
for (NotificationSubscriber *subscriber : qAsConst(mSubscribers)) {
if (subscriber->notify(notification)) {
listeners.push_back(subscriber->subscriber());
}
......
......@@ -384,7 +384,7 @@ QString DbInitializer::referentialActionToString(ColumnDescription::ReferentialA
QString DbInitializer::buildPrimaryKeyStatement(const TableDescription &table)
{
QStringList cols;
Q_FOREACH (const ColumnDescription &column, table.columns) {
for (const ColumnDescription &column : qAsConst(table.columns)) {
if (column.isPrimaryKey) {
cols.push_back(column.name);
}
......
......@@ -198,7 +198,7 @@ namespace
{
static bool hasAllParts(ItemRetrievalRequest *req, const QSet<QByteArray> &availableParts)
{
Q_FOREACH (const auto &part, req->parts) {
for (const auto &part : qAsConst(req->parts)) {
if (!availableParts.contains(part)) {
return false;
}
......
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