Skip to content
Permalink
Browse files

Fix crash on map themes manager and null layers

  • Loading branch information
github-actions authored and nyalldawson committed Jan 28, 2020
1 parent 3944db4 commit e28feaf5fd3dc1619dd121f97c4b7c9a0dc140ae
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/core/qgsmapthemecollection.cpp
@@ -93,7 +93,7 @@ void QgsMapThemeCollection::createThemeFromCurrentState( QgsLayerTreeGroup *pare
else if ( QgsLayerTree::isLayer( node ) )
{
QgsLayerTreeLayer *nodeLayer = QgsLayerTree::toLayer( node );
if ( node->itemVisibilityChecked() != Qt::Unchecked )
if ( node->itemVisibilityChecked() != Qt::Unchecked && nodeLayer->layer() )
rec.mLayerRecords << createThemeLayerRecord( nodeLayer, model );
}
}

0 comments on commit e28feaf

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