Skip to content

Commit

Permalink
Check crs before filtering
Browse files Browse the repository at this point in the history
  • Loading branch information
Joonalai committed Jan 15, 2025
1 parent d25082a commit da156b7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/app/vertextool/qgsvertextool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2221,13 +2221,13 @@ void QgsVertexTool::moveVertex( const QgsPointXY &mapPoint, const QgsPointLocato
if ( !( vectorLayer->geometryType() == Qgis::GeometryType::Polygon || vectorLayer->geometryType() == Qgis::GeometryType::Line ) )
continue;

if ( !vectorLayer->getFeatures( request ).nextFeature( f ) )
continue;

// layer's CRS need to be the the same (otherwise we would need to reproject the point and it will not be coincident)
if ( vectorLayer->crs() != itLayerEdits.key()->crs() )
continue;

if ( !vectorLayer->getFeatures( request ).nextFeature( f ) )
continue;

vectorLayer->beginEditCommand( tr( "Topological points added by 'Vertex Tool'" ) );

bool topoPointsAdded = false;
Expand Down

0 comments on commit da156b7

Please sign in to comment.