Skip to content

Commit

Permalink
Fix field widget wrapper
Browse files Browse the repository at this point in the history
  • Loading branch information
nyalldawson committed Jun 6, 2017
1 parent f0f0411 commit 74ffdb1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions python/plugins/processing/gui/wrappers.py
Expand Up @@ -1173,6 +1173,8 @@ def parentValueChanged(self, wrapper):

def setLayer(self, layer):
context = dataobjects.createContext()
if isinstance(layer, QgsProcessingFeatureSourceDefinition):
layer, ok = layer.source.valueAsString(context.expressionContext())
if isinstance(layer, str):
layer = QgsProcessingUtils.mapLayerFromString(layer, context)
self._layer = layer
Expand Down

0 comments on commit 74ffdb1

Please sign in to comment.