From 8b430d214325110460cf69360d36ba567025c18b Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Wed, 7 Feb 2018 16:36:30 +0100 Subject: Fixed warning --- common/datastorequery.cpp | 8 ++++---- common/typeindex.cpp | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'common') diff --git a/common/datastorequery.cpp b/common/datastorequery.cpp index f5152b7..870daf8 100644 --- a/common/datastorequery.cpp +++ b/common/datastorequery.cpp @@ -302,7 +302,7 @@ public: auto selectionResult = reduceOnValue(reductionValue, aggregateValues); mSelectedValues.insert(reductionValueBa, selectionResult); - readEntity(selectionResult, [&, this](const Sink::ApplicationDomain::ApplicationDomainType &entity, Sink::Operation operation) { + readEntity(selectionResult, [&](const Sink::ApplicationDomain::ApplicationDomainType &entity, Sink::Operation operation) { callback({entity, operation, aggregateValues}); foundValue = true; }); @@ -320,18 +320,18 @@ public: auto oldSelectionResult = mSelectedValues.take(reductionValueBa); if (oldSelectionResult == selectionResult) { mSelectedValues.insert(reductionValueBa, selectionResult); - readEntity(selectionResult, [&, this](const Sink::ApplicationDomain::ApplicationDomainType &entity, Sink::Operation) { + readEntity(selectionResult, [&](const Sink::ApplicationDomain::ApplicationDomainType &entity, Sink::Operation) { callback({entity, Sink::Operation_Modification, aggregateValues}); }); } else { //remove old result - readEntity(oldSelectionResult, [&, this](const Sink::ApplicationDomain::ApplicationDomainType &entity, Sink::Operation) { + readEntity(oldSelectionResult, [&](const Sink::ApplicationDomain::ApplicationDomainType &entity, Sink::Operation) { callback({entity, Sink::Operation_Removal}); }); //add new result mSelectedValues.insert(reductionValueBa, selectionResult); - readEntity(selectionResult, [&, this](const Sink::ApplicationDomain::ApplicationDomainType &entity, Sink::Operation) { + readEntity(selectionResult, [&](const Sink::ApplicationDomain::ApplicationDomainType &entity, Sink::Operation) { callback({entity, Sink::Operation_Creation, aggregateValues}); }); } diff --git a/common/typeindex.cpp b/common/typeindex.cpp index 5a19839..0228ecb 100644 --- a/common/typeindex.cpp +++ b/common/typeindex.cpp @@ -245,7 +245,7 @@ QVector TypeIndex::lookup(const QByteArray &property, const QVariant Index index(indexName(property), transaction); const auto lookupKey = getByteArray(value); index.lookup( - lookupKey, [&, this](const QByteArray &value) { keys << value; }, [property, this](const Index::Error &error) { SinkWarning() << "Error in index: " << error.message << property; }); + lookupKey, [&](const QByteArray &value) { keys << value; }, [property](const Index::Error &error) { SinkWarning() << "Error in index: " << error.message << property; }); SinkTraceCtx(mLogCtx) << "Index lookup on " << property << " found " << keys.size() << " keys."; return keys; } else if (mSecondaryProperties.contains(property)) { @@ -257,7 +257,7 @@ QVector TypeIndex::lookup(const QByteArray &property, const QVariant Index index(indexName(property + resultProperty), transaction); const auto lookupKey = getByteArray(value); index.lookup( - lookupKey, [&, this](const QByteArray &value) { secondaryKeys << value; }, [property, this](const Index::Error &error) { SinkWarning() << "Error in index: " << error.message << property; }); + lookupKey, [&](const QByteArray &value) { secondaryKeys << value; }, [property](const Index::Error &error) { SinkWarning() << "Error in index: " << error.message << property; }); SinkTraceCtx(mLogCtx) << "Looked up secondary keys: " << secondaryKeys; for (const auto &secondary : secondaryKeys) { keys += lookup(resultProperty, secondary, transaction); -- cgit v1.2.3