Skip to content

Commit

Permalink
[processing] Fix some exceptions
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed May 15, 2018
1 parent c9e5a36 commit 74b0e91
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/qgis/BasicStatistics.py
Expand Up @@ -134,7 +134,7 @@ def displayName(self):
def processAlgorithm(self, parameters, context, feedback):
source = self.parameterAsSource(parameters, self.INPUT_LAYER, context)
if source is None:
raise QgsProcessingException(self.invalidSourceError(parameters, self.INPUT))
raise QgsProcessingException(self.invalidSourceError(parameters, self.INPUT_LAYER))

field_name = self.parameterAsString(parameters, self.FIELD_NAME, context)
field = source.fields().at(source.fields().lookupField(field_name))
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/qgis/CheckValidity.py
Expand Up @@ -127,7 +127,7 @@ def processAlgorithm(self, parameters, context, feedback):
def doCheck(self, method, parameters, context, feedback):
source = self.parameterAsSource(parameters, self.INPUT_LAYER, context)
if source is None:
raise QgsProcessingException(self.invalidSourceError(parameters, self.INPUT))
raise QgsProcessingException(self.invalidSourceError(parameters, self.INPUT_LAYER))

(valid_output_sink, valid_output_dest_id) = self.parameterAsSink(parameters, self.VALID_OUTPUT, context,
source.fields(), source.wkbType(), source.sourceCrs())
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/qgis/PointsFromLines.py
Expand Up @@ -76,7 +76,7 @@ def displayName(self):
def processAlgorithm(self, parameters, context, feedback):
source = self.parameterAsSource(parameters, self.INPUT_VECTOR, context)
if source is None:
raise QgsProcessingException(self.invalidSourceError(parameters, self.INPUT))
raise QgsProcessingException(self.invalidSourceError(parameters, self.INPUT_VECTOR))

raster_layer = self.parameterAsRasterLayer(parameters, self.INPUT_RASTER, context)
rasterPath = raster_layer.source()
Expand Down
2 changes: 1 addition & 1 deletion python/plugins/processing/algs/qgis/PointsFromPolygons.py
Expand Up @@ -76,7 +76,7 @@ def displayName(self):
def processAlgorithm(self, parameters, context, feedback):
source = self.parameterAsSource(parameters, self.INPUT_VECTOR, context)
if source is None:
raise QgsProcessingException(self.invalidSourceError(parameters, self.INPUT))
raise QgsProcessingException(self.invalidSourceError(parameters, self.INPUT_VECTOR))

raster_layer = self.parameterAsRasterLayer(parameters, self.INPUT_RASTER, context)
rasterPath = raster_layer.source()
Expand Down

0 comments on commit 74b0e91

Please sign in to comment.