Skip to content

Commit eb92999

Browse files
committed
Merge pull request #1083 from Oslandia/fix_max_on_joined_fields
fix bug in max value on joined fields
2 parents 3568fe7 + 80b44a7 commit eb92999

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/app/qgsdiagramproperties.cpp

+2-3
Original file line numberDiff line numberDiff line change
@@ -445,8 +445,7 @@ void QgsDiagramProperties::on_mFindMaximumValueButton_clicked()
445445
//get maximum value from provider (ignoring not-commited edits)
446446
if ( mLayer )
447447
{
448-
QgsVectorDataProvider* provider = mLayer->dataProvider();
449-
if ( provider )
448+
// condition removed, keep this useless scope to avoid screewing diff (easier to review)
450449
{
451450
float maxValue = 0;
452451
if ( mSizeAttributeComboBox->currentIndex() >= mAvailableAttributes )
@@ -469,7 +468,7 @@ void QgsDiagramProperties::on_mFindMaximumValueButton_clicked()
469468
}
470469
else
471470
{
472-
maxValue = provider->maximumValue( mSizeAttributeComboBox->itemData( mSizeAttributeComboBox->currentIndex() ).toInt() ).toFloat();
471+
maxValue = mLayer->maximumValue( mSizeAttributeComboBox->itemData( mSizeAttributeComboBox->currentIndex() ).toInt() ).toFloat();
473472
}
474473
mValueLineEdit->setText( QString( "%1" ).arg( maxValue ) );
475474
}

0 commit comments

Comments
 (0)