Skip to content

Commit

Permalink
change empty '' with None
Browse files Browse the repository at this point in the history
  • Loading branch information
ghtmtt authored and nyalldawson committed May 17, 2018
1 parent 5710698 commit 2a7c10e
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/gdal/ClipRasterByExtent.py
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/gdal/ClipRasterByMask.py
Original file line number Diff line number Diff line change
Expand Up @@ -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'),
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/gdal/contour.py
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down

0 comments on commit 2a7c10e

Please sign in to comment.