Skip to content
Permalink
Browse files

Fix QgsLayerDefinition::loadLayerDefinition

  • Loading branch information
elpaso committed Nov 9, 2020
1 parent c913308 commit 525adede355ef54ca23742097201e8e83f1cb556
Showing with 1 addition and 3 deletions.
  1. +1 −3 src/core/qgslayerdefinition.cpp
@@ -186,9 +186,7 @@ bool QgsLayerDefinition::loadLayerDefinition( QDomDocument doc, QgsProject *proj
root->resolveReferences( project );

QList<QgsLayerTreeNode *> nodes = root->children();
const auto constNodes = nodes;
for ( QgsLayerTreeNode *node : constNodes )
root->takeChild( node );
root->abandonChildren();
delete root;

rootGroup->insertChildNodes( -1, nodes );

0 comments on commit 525aded

Please sign in to comment.
You can’t perform that action at this time.