Skip to content

Commit

Permalink
Cleaner code
Browse files Browse the repository at this point in the history
(cherry-picked from 0c1f89c)
  • Loading branch information
nyalldawson committed Jul 17, 2018
1 parent 4c3174c commit 5ee4d8f
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/core/qgsofflineediting.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1254,7 +1254,7 @@ QgsOfflineEditing::GeometryChanges QgsOfflineEditing::sqlQueryGeometryChanges( s
void QgsOfflineEditing::committedAttributesAdded( const QString &qgisLayerId, const QList<QgsField> &addedAttributes )
{
sqlite3_database_unique_ptr database = openLoggingDb();
if ( !database.get() )
if ( !database )
return;

// insert log
Expand All @@ -1281,7 +1281,7 @@ void QgsOfflineEditing::committedAttributesAdded( const QString &qgisLayerId, co
void QgsOfflineEditing::committedFeaturesAdded( const QString &qgisLayerId, const QgsFeatureList &addedFeatures )
{
sqlite3_database_unique_ptr database = openLoggingDb();
if ( !database.get() )
if ( !database )
return;

// insert log
Expand All @@ -1306,7 +1306,7 @@ void QgsOfflineEditing::committedFeaturesAdded( const QString &qgisLayerId, cons
void QgsOfflineEditing::committedFeaturesRemoved( const QString &qgisLayerId, const QgsFeatureIds &deletedFeatureIds )
{
sqlite3_database_unique_ptr database = openLoggingDb();
if ( !database.get() )
if ( !database )
return;

// insert log
Expand All @@ -1333,7 +1333,7 @@ void QgsOfflineEditing::committedFeaturesRemoved( const QString &qgisLayerId, co
void QgsOfflineEditing::committedAttributeValuesChanges( const QString &qgisLayerId, const QgsChangedAttributesMap &changedAttrsMap )
{
sqlite3_database_unique_ptr database = openLoggingDb();
if ( !database.get() )
if ( !database )
return;

// insert log
Expand Down Expand Up @@ -1367,7 +1367,7 @@ void QgsOfflineEditing::committedAttributeValuesChanges( const QString &qgisLaye
void QgsOfflineEditing::committedGeometriesChanges( const QString &qgisLayerId, const QgsGeometryMap &changedGeometries )
{
sqlite3_database_unique_ptr database = openLoggingDb();
if ( !database.get() )
if ( !database )
return;

// insert log
Expand Down

0 comments on commit 5ee4d8f

Please sign in to comment.