Skip to content
Permalink
Browse files

Raise an exception if the necessary parameter was not specified

  • Loading branch information
wonder-sk committed Apr 25, 2019
1 parent fdb6a2b commit e6ff7e00ef681d67be87ddda329350dbe962700f
Showing with 4 additions and 0 deletions.
  1. +4 −0 python/plugins/processing/algs/qgis/TilesXYZ.py
@@ -288,8 +288,12 @@ def processAlgorithm(self, parameters, context, feedback):
output_format = self.outputs[self.parameterAsEnum(parameters, self.OUTPUT_FORMAT, context)]
if output_format == 'Directory':
output_dir = self.parameterAsString(parameters, self.OUTPUT_DIRECTORY, context)
if not output_dir:
raise QgsProcessingException(self.tr('You need to specify output directory.'))
else: # MBTiles
output_file = self.parameterAsString(parameters, self.OUTPUT_FILE, context)
if not output_file:
raise QgsProcessingException(self.tr('You need to specify output filename.'))
tile_width = 256
tile_height = 256

0 comments on commit e6ff7e0

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