Skip to content

Commit

Permalink
Fix compiler warning
Browse files Browse the repository at this point in the history
  • Loading branch information
m-kuhn authored and nirvn committed Jan 18, 2019
1 parent 6e0930a commit 01e2b80
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/core/expression/qgsexpressionfunction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4581,6 +4581,7 @@ static QVariant fcnLoadJson( const QVariantList &values, const QgsExpressionCont

static QVariant fcnWriteJson( const QVariantList &values, const QgsExpressionContext *, QgsExpression *parent, const QgsExpressionNodeFunction * )
{
Q_UNUSED( parent )
QJsonDocument document = QJsonDocument::fromVariant( values.at( 0 ) );
return document.toJson( QJsonDocument::Compact );
}
Expand Down Expand Up @@ -5299,9 +5300,9 @@ const QList<QgsExpressionFunction *> &QgsExpression::Functions()

//functions for maps
<< new QgsStaticExpressionFunction( QStringLiteral( "json_to_map" ), 1, fcnLoadJson, QStringLiteral( "Maps" ) )
<< new QgsStaticExpressionFunction( QStringLiteral( "load_json" ), 1, fcnLoadJson, QStringLiteral( "Maps" ) )
<< new QgsStaticExpressionFunction( QStringLiteral( "load_json" ), QgsExpressionFunction::ParameterList() << QgsExpressionFunction::Parameter( QStringLiteral( "value" ) ), fcnLoadJson, QStringLiteral( "Maps" ) )
<< new QgsStaticExpressionFunction( QStringLiteral( "map_to_json" ), 1, fcnWriteJson, QStringLiteral( "Maps" ) )
<< new QgsStaticExpressionFunction( QStringLiteral( "write_json" ), 1, fcnWriteJson, QStringLiteral( "Maps" ) )
<< new QgsStaticExpressionFunction( QStringLiteral( "write_json" ), QgsExpressionFunction::ParameterList() << QgsExpressionFunction::Parameter( QStringLiteral( "json_string" ) ), fcnWriteJson, QStringLiteral( "Maps" ) )
<< new QgsStaticExpressionFunction( QStringLiteral( "hstore_to_map" ), 1, fcnHstoreToMap, QStringLiteral( "Maps" ) )
<< new QgsStaticExpressionFunction( QStringLiteral( "map_to_hstore" ), 1, fcnMapToHstore, QStringLiteral( "Maps" ) )
<< new QgsStaticExpressionFunction( QStringLiteral( "map" ), -1, fcnMap, QStringLiteral( "Maps" ) )
Expand Down

0 comments on commit 01e2b80

Please sign in to comment.