Skip to content

Commit

Permalink
Allow updating SSL cert custom configuration
Browse files Browse the repository at this point in the history
So far it was only possible to add a first configuration, changing the configuration later on would fail with a unique constraint error.
  • Loading branch information
m-kuhn committed Jul 2, 2018
1 parent 7e7faad commit 85b382c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/core/auth/qgsauthmanager.cpp
Expand Up @@ -1937,7 +1937,7 @@ bool QgsAuthManager::storeSslCertCustomConfig( const QgsAuthConfigSslServer &con
QString certpem( cert.toPem() );

QSqlQuery query( authDatabaseConnection() );
query.prepare( QString( "INSERT INTO %1 (id, host, cert, config) "
query.prepare( QString( "INSERT OR REPLACE INTO %1 (id, host, cert, config) "
"VALUES (:id, :host, :cert, :config)" ).arg( authDatabaseServersTable() ) );

query.bindValue( QStringLiteral( ":id" ), id );
Expand Down

0 comments on commit 85b382c

Please sign in to comment.