Skip to content

Commit

Permalink
QgsMeshLayer::closestEdge(): remove useless nullptr check as we have…
Browse files Browse the repository at this point in the history
… already dereferenced mesh
  • Loading branch information
rouault committed May 29, 2020
1 parent 725541d commit 1abc2de
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/core/mesh/qgsmeshlayer.cpp
Expand Up @@ -603,8 +603,7 @@ int QgsMeshLayer::closestEdge( const QgsPointXY &point, double searchRadius, Qgs
// search for the closest edge in search area from point
const QList<int> edgeIndexes = mesh->edgeIndexesForRectangle( searchRectangle );
int selectedIndex = -1;
if ( mesh &&
mesh->contains( QgsMesh::Edge ) &&
if ( mesh->contains( QgsMesh::Edge ) &&
mDataProvider->isValid() )
{
double sqrMaxDistFromPoint = pow( searchRadius, 2 );
Expand Down

0 comments on commit 1abc2de

Please sign in to comment.