Skip to content
Browse files

[Processing][Modeler] Use default value instead of None

In Modeler algorithm, when a algorithm's parameter was not defined it's value was set to None.
Before the possibility to defined optional parameters, None value is equal to set value to default one.
Now, it's important to use default value instead of None.
  • Loading branch information
rldhont committed Apr 27, 2016
1 parent e9bc8ae commit 4a11a1a3198dba0f2e3592ca345c6cbda5d020c1
@@ -389,7 +389,7 @@ def prepareAlgorithm(self, alg):
iface.messageBar().pushMessage("Warning"),"Parameter %s in algorithm %s in the model is run with default value! Edit the model to make sure that this is correct.") % (,,
QgsMessageBar.WARNING, 4)
value = None
value = param.default
if value is None and isinstance(param, ParameterExtent):
value = self.getMinCoveringExtent()
# We allow unexistent filepaths, since that allows
@@ -454,7 +454,7 @@ def setPreviousValues(self):
if in alg.params:
value = alg.params[]
value = None
value = param.default
if isinstance(param, (

0 comments on commit 4a11a1a

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