summaryrefslogtreecommitdiff
path: root/slicer/db/sqlUpdateSerializer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'slicer/db/sqlUpdateSerializer.cpp')
-rw-r--r--slicer/db/sqlUpdateSerializer.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/slicer/db/sqlUpdateSerializer.cpp b/slicer/db/sqlUpdateSerializer.cpp
index c054764..152c923 100644
--- a/slicer/db/sqlUpdateSerializer.cpp
+++ b/slicer/db/sqlUpdateSerializer.cpp
@@ -49,9 +49,10 @@ namespace Slicer {
void
SqlUpdateSerializer::SerializeSequence(ModelPartParam mp) const
{
- auto ins = createUpdate(mp->GetContainedModelPart());
- mp->OnEachChild([&ins](auto &&, auto && cmp, auto &&) {
- bindObjectAndExecute(cmp, ins.get());
+ mp->OnContained([this, mp](auto && cmp) {
+ mp->OnEachChild([upd = createUpdate(cmp)](auto &&, auto && chmp, auto &&) {
+ bindObjectAndExecute(chmp, upd.get());
+ });
});
}