Skip to content

Commit

Permalink
[libcommhistory] Make build with latest qtpim. JB#50658
Browse files Browse the repository at this point in the history
  • Loading branch information
Bea Lam committed Sep 15, 2020
1 parent 5fbec3d commit 6f52be8
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions tests/common.cpp
Expand Up @@ -234,8 +234,8 @@ int addTestContact(const QString &name, const QString &remoteUid, const QString
return -1;
}

foreach (const QContactRelationship &relationship, manager()->relationships(QContactRelationship::Aggregates(), contact, QContactRelationship::Second)) {
const QContactId &aggId = relationship.first().id();
foreach (const QContactRelationship &relationship, manager()->relationships(QContactRelationship::Aggregates(), contact.id(), QContactRelationship::Second)) {
const QContactId &aggId = relationship.first();
qDebug() << "********** contact id" << aggId;
addedContactIds.insert(aggId);
return internalContactId(aggId);
Expand Down Expand Up @@ -269,8 +269,8 @@ QList<int> addTestContacts(const QList<QPair<QString, QPair<QString, QString> >
constituentIds.insert(contact.id());
}
foreach (const QContactRelationship &relationship, manager()->relationships(QContactRelationship::Aggregates())) {
if (constituentIds.contains(relationship.second().id())) {
const QContactId &aggId = relationship.first().id();
if (constituentIds.contains(relationship.second())) {
const QContactId &aggId = relationship.first();
qDebug() << "********** contact id" << aggId;
addedContactIds.insert(aggId);
ids.append(internalContactId(aggId));
Expand Down Expand Up @@ -373,8 +373,8 @@ void cleanUpTestContacts()
QString aggregatesType = QContactRelationship::Aggregates();

foreach (const QContactRelationship &rel, manager()->relationships(aggregatesType)) {
QContactId firstId = rel.first().id();
QContactId secondId = rel.second().id();
QContactId firstId = rel.first();
QContactId secondId = rel.second();
if (addedContactIds.contains(firstId)) {
addedContactIds.insert(secondId);
}
Expand Down

0 comments on commit 6f52be8

Please sign in to comment.