From 12dbe4312e2f32c2e1e096b861d79f35d21d307c Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Sun, 26 Aug 2018 13:54:20 +0100 Subject: Remove unnecessary captures --- slicer/db/sqlInsertSerializer.cpp | 2 +- slicer/db/sqlUpdateSerializer.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/slicer/db/sqlInsertSerializer.cpp b/slicer/db/sqlInsertSerializer.cpp index 90f97bb..223f739 100644 --- a/slicer/db/sqlInsertSerializer.cpp +++ b/slicer/db/sqlInsertSerializer.cpp @@ -88,7 +88,7 @@ namespace Slicer { SqlFetchIdInsertSerializer::bindObjectAndExecute(Slicer::ModelPartPtr cmp, DB::ModifyCommand * ins) const { SqlAutoIdInsertSerializer::bindObjectAndExecute(cmp, ins); - cmp->OnEachChild([&ins, this](const std::string &, ModelPartPtr cmp, const HookCommon * h) { + cmp->OnEachChild([this](const std::string &, ModelPartPtr cmp, const HookCommon * h) { if (isAuto(h)) { cmp->SetValue(IdSave(connection)); } diff --git a/slicer/db/sqlUpdateSerializer.cpp b/slicer/db/sqlUpdateSerializer.cpp index 7629573..07d6f15 100644 --- a/slicer/db/sqlUpdateSerializer.cpp +++ b/slicer/db/sqlUpdateSerializer.cpp @@ -43,7 +43,7 @@ namespace Slicer { SqlUpdateSerializer::SerializeSequence(Slicer::ModelPartPtr mp) const { auto ins = createUpdate(mp->GetContainedModelPart()); - mp->OnEachChild([&ins, this](const std::string &, ModelPartPtr cmp, const HookCommon *) { + mp->OnEachChild([&ins](const std::string &, ModelPartPtr cmp, const HookCommon *) { bindObjectAndExecute(cmp, ins.get()); }); } -- cgit v1.2.3