Skip to content
Permalink
Browse files

added check if no gemetry is available

  • Loading branch information
luipir committed Jun 12, 2017
1 parent fdd5a50 commit 008cc79d9f04347dbbe0d16ab77e0398db5b855f
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/core/qgsvectorlayereditbuffer.cpp
@@ -320,7 +320,8 @@ bool QgsVectorLayerEditBuffer::commitChanges( QStringList &commitErrors )
{
for ( QgsFeature f : mAddedFeatures )
{
if ( f.geometry().wkbType() == provider->wkbType() )
if ( ( ! f.hasGeometry() ) ||
( f.geometry().wkbType() == provider->wkbType() ) )
continue;

std::unique_ptr<QgsGeometry> convertedGeom( provider->convertToProviderType( f.geometry() ) );

0 comments on commit 008cc79

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