Skip to content

Commit

Permalink
[processing] Fix exception from field wrappers when "selected feature…
Browse files Browse the repository at this point in the history
…s only"

is checked for a vector layer
  • Loading branch information
nyalldawson committed Jun 25, 2019
1 parent efeb8b5 commit 4a4b922
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions python/plugins/processing/gui/wrappers.py
Expand Up @@ -1541,11 +1541,12 @@ def postInitialize(self, wrappers):

def parentValueChanged(self, wrapper):
value = wrapper.parameterValue()
if value in self.parent_file_based_layers:
if isinstance(value, str) and value in self.parent_file_based_layers:
self.setLayer(self.parent_file_based_layers[value])
else:
self.setLayer(value)
self.parent_file_based_layers[value] = self._layer
if isinstance(value, str):
self.parent_file_based_layers[value] = self._layer

def setLayer(self, layer):
if isinstance(layer, QgsProcessingFeatureSourceDefinition):
Expand Down

0 comments on commit 4a4b922

Please sign in to comment.