Skip to content

Commit

Permalink
More efficient QSet intersection test
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Jan 28, 2021
1 parent 1d2d40e commit 0c238df
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/providers/hana/qgshanatablemodel.cpp
Expand Up @@ -247,7 +247,7 @@ bool QgsHanaTableModel::setData( const QModelIndex &idx, const QVariant &value,
{
QSet<QString> s0( qgis::listToSet( idx.sibling( idx.row(), DbtmPkCol ).data( Qt::UserRole + 2 ).toStringList() ) );
QSet<QString> s1( qgis::listToSet( pkCols ) );
if ( s0.intersect( s1 ).isEmpty() )
if ( !s0.intersects( s1 ) )
tip = tr( "Select columns in the '%1' column that uniquely identify features of this layer" ).arg( tr( "Feature id" ) );
}

Expand Down

0 comments on commit 0c238df

Please sign in to comment.