Skip to content
Permalink
Browse files

Fix escaping of quotes of map layer source in processing

  • Loading branch information
wonder-sk committed Jun 22, 2018
1 parent 17ea4a9 commit 0a225c485fcc7bee5dd71d65852c8afd0c87d7e4
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/core/processing/qgsprocessingparameters.cpp
@@ -3155,7 +3155,7 @@ QString QgsProcessingParameterFeatureSource::valueAsPythonString( const QVariant
// prefer to use layer source instead of id if possible (since it's persistent)
if ( QgsVectorLayer *layer = qobject_cast< QgsVectorLayer * >( QgsProcessingUtils::mapLayerFromString( layerString, context ) ) )
layerString = layer->source();
return layerString.prepend( '\'' ).append( '\'' );
return QgsProcessingUtils::stringToPythonLiteral( layerString );
}
}
else

0 comments on commit 0a225c4

Please sign in to comment.
You can’t perform that action at this time.