Skip to content

Commit

Permalink
Fix another test
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Mar 14, 2020
1 parent 3c11776 commit 55d3761
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/core/processing/qgsprocessingalgorithm.cpp
Expand Up @@ -603,7 +603,7 @@ QgsFeatureSink *QgsProcessingAlgorithm::parameterAsSink( const QVariantMap &para
{
return QgsProcessingParameters::parameterAsSink( parameterDefinition( name ), parameters, fields, geometryType, crs, context, destinationIdentifier, sinkFlags );
}
catch ( QgsProcessingException )
catch ( QgsProcessingException & )
{
throw QgsProcessingException( QObject::tr( "No parameter definition for the sink '%1'" ).arg( name ) );
}
Expand Down
10 changes: 8 additions & 2 deletions src/gui/qgsdatabasetablecombobox.cpp
Expand Up @@ -128,8 +128,14 @@ void QgsDatabaseTableComboBox::setConnectionName( const QString &connection, con
const QString oldTable = currentTable();
const QString oldSchema = currentSchema();
QgsDatabaseTableModel *oldModel = mModel;
mModel = new QgsDatabaseTableModel( mProvider, mConnection, mSchema, this );
mModel->setAllowEmptyTable( mAllowEmpty );
if ( !mConnection.isEmpty() )
{
mModel = new QgsDatabaseTableModel( mProvider, mConnection, mSchema, this );
mModel->setAllowEmptyTable( mAllowEmpty );
}
else
mModel = nullptr;

mSortModel->setSourceModel( mModel );
if ( oldModel )
oldModel->deleteLater();
Expand Down

0 comments on commit 55d3761

Please sign in to comment.