Skip to content

Commit

Permalink
Allow unprepared execution of QgsExpression
Browse files Browse the repository at this point in the history
  • Loading branch information
m-kuhn committed May 22, 2013
1 parent b7f1987 commit 6af9261
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/core/qgsexpression.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2243,7 +2243,10 @@ QVariant QgsExpression::NodeColumnRef::eval( QgsExpression* /*parent*/, QgsFeatu
{
if ( f )
{
return f->attribute( mIndex );
if ( mIndex >= 0 )
return f->attribute( mIndex );
else
return f->attribute( mName );
}
return QVariant( "[" + mName + "]" );
}
Expand Down

0 comments on commit 6af9261

Please sign in to comment.