Skip to content

Commit

Permalink
change handling
Browse files Browse the repository at this point in the history
  • Loading branch information
roya0045 committed Dec 8, 2021
1 parent 75f1b37 commit c30d996
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/core/expression/qgsexpressionfunction.cpp
Expand Up @@ -5477,13 +5477,13 @@ static QVariant fcnGetFeature( const QVariantList &values, const QgsExpressionCo
}
QgsFeatureRequest req;
QString cacheValueKey;
if ( values.size() == 2 && values.at( 1 ).canConvert<QVariantMap>() )
if ( values.size() == 2 && values.at( 1 ).type() == QVariant::Map )
{
QVariantMap map = values.at( 1 ).toMap();
QVariantMap attributeMap = QgsExpressionUtils::getMapValue( values.at( 1 ), parent );

QMap <QString, QVariant>::const_iterator i = map.constBegin();
QMap <QString, QVariant>::const_iterator i = attributeMap.constBegin();
QString filterString;
for ( ; i != map.constEnd(); ++i )
for ( ; i != attributeMap.constEnd(); ++i )
{
if ( !filterString.isEmpty() )
{
Expand Down

0 comments on commit c30d996

Please sign in to comment.