diff --git a/src/core/qgsvectordataprovider.cpp b/src/core/qgsvectordataprovider.cpp index 654ca2a799d..2d04c1b14ec 100644 --- a/src/core/qgsvectordataprovider.cpp +++ b/src/core/qgsvectordataprovider.cpp @@ -700,7 +700,7 @@ bool QgsVectorDataProvider::isDeleteStyleFromDBSupported() const return false; } -void QgsVectorDataProvider::deleteStyleById( const QString& uri, QString styleId, QString& errCause ) +void QgsVectorDataProvider::deleteStyleById( const QString& uri, QString styleId, QString& errCause ) const { Q_UNUSED( uri ); Q_UNUSED( styleId ); diff --git a/src/core/qgsvectordataprovider.h b/src/core/qgsvectordataprovider.h index 0bdac0a2177..91e73c72812 100644 --- a/src/core/qgsvectordataprovider.h +++ b/src/core/qgsvectordataprovider.h @@ -479,7 +479,7 @@ class CORE_EXPORT QgsVectorDataProvider : public QgsDataProvider /** * Deletes an existing style from the provider */ - virtual void deleteStyleById( const QString& uri, QString styleId, QString& errCause ); + virtual void deleteStyleById( const QString& uri, QString styleId, QString& errCause ) const; static QVariant convertValue( QVariant::Type type, const QString& value ); diff --git a/src/providers/postgres/qgspostgresprovider.cpp b/src/providers/postgres/qgspostgresprovider.cpp index 38393659c42..e64047bcb9c 100644 --- a/src/providers/postgres/qgspostgresprovider.cpp +++ b/src/providers/postgres/qgspostgresprovider.cpp @@ -4632,12 +4632,8 @@ QGISEXTERN int listStyles( const QString &uri, QStringList &ids, QStringList &na return numberOfRelatedStyles; } -void QgsPostgresProvider::deleteStyleById( const QString &uri, QString styleId, QString &errCause ) +void QgsPostgresProvider::deleteStyleById( const QString &uri, QString styleId, QString &errCause ) const { - QgsDebugMsg( "deleteStyleById" ); - QgsDebugMsg( styleId ); - QgsDebugMsg( uri ); - QgsDataSourceUri dsUri( uri ); QgsPostgresConn *conn = QgsPostgresConn::connectDb( dsUri.connectionInfo( false ), false ); diff --git a/src/providers/postgres/qgspostgresprovider.h b/src/providers/postgres/qgspostgresprovider.h index c75fd52ccec..9943099bf23 100644 --- a/src/providers/postgres/qgspostgresprovider.h +++ b/src/providers/postgres/qgspostgresprovider.h @@ -133,7 +133,7 @@ class QgsPostgresProvider : public QgsVectorDataProvider bool isValid() const override; virtual bool isSaveAndLoadStyleToDBSupported() const override { return true; } virtual bool isDeleteStyleFromDBSupported() const override { return true; } - void deleteStyleById( const QString& uri, QString styleId, QString& errCause ); + void deleteStyleById( const QString& uri, QString styleId, QString& errCause ) const override; QgsAttributeList attributeIndexes() const override; QgsAttributeList pkAttributeIndexes() const override { return mPrimaryKeyAttrs; } QString defaultValueClause( int fieldId ) const override;