Skip to content
Permalink
Browse files

change empty '' with None

  • Loading branch information
ghtmtt authored and nyalldawson committed May 17, 2018
1 parent 5710698 commit 2a7c10e719487b310af0e41f54f817aba0bc808f
@@ -67,7 +67,7 @@ def initAlgorithm(self, config=None):
self.addParameter(QgsProcessingParameterNumber(self.NODATA,
self.tr('Assign a specified nodata value to output bands'),
type=QgsProcessingParameterNumber.Double,
defaultValue='',
defaultValue=None,
optional=True))

options_param = QgsProcessingParameterString(self.OPTIONS,
@@ -72,7 +72,7 @@ def initAlgorithm(self, config=None):
self.addParameter(QgsProcessingParameterNumber(self.NODATA,
self.tr('Assign a specified nodata value to output bands'),
type=QgsProcessingParameterNumber.Double,
defaultValue='',
defaultValue=None,
optional=True))
self.addParameter(QgsProcessingParameterBoolean(self.ALPHA_BAND,
self.tr('Create an output alpha band'),
@@ -91,7 +91,7 @@ def initAlgorithm(self, config=None):
nodata_param = QgsProcessingParameterNumber(self.NODATA,
self.tr('Input pixel value to treat as "nodata"'),
type=QgsProcessingParameterNumber.Double,
defaultValue='',
defaultValue=None,
optional=True)
nodata_param.setFlags(nodata_param.flags() | QgsProcessingParameterDefinition.FlagAdvanced)
self.addParameter(nodata_param)

0 comments on commit 2a7c10e

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