Skip to content

Commit

Permalink
Fixes #11349 - field calculator broke on qgis master
Browse files Browse the repository at this point in the history
  • Loading branch information
slarosa committed Oct 7, 2014
1 parent ac1e9cb commit fbc5f06
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/app/qgsfieldcalculator.cpp
Expand Up @@ -127,8 +127,6 @@ void QgsFieldCalculator::accept()
return;
}

const QgsField& field = mVectorLayer->pendingFields()[mAttributeId];

QApplication::setOverrideCursor( Qt::WaitCursor );

mVectorLayer->beginEditCommand( "Field calculator" );
Expand Down Expand Up @@ -197,6 +195,8 @@ void QgsFieldCalculator::accept()
bool useGeometry = exp.needsGeometry();
int rownum = 1;

const QgsField& field = mVectorLayer->pendingFields()[mAttributeId];

bool newField = !mUpdateExistingGroupBox->isChecked();
QVariant emptyAttribute;
if ( newField )
Expand Down

0 comments on commit fbc5f06

Please sign in to comment.