Skip to content

Commit 8af308d

Browse files
committed
Fix creation of widget wrappers via metadata parameters
1 parent 1b696a7 commit 8af308d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

python/plugins/processing/gui/wrappers.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -1254,14 +1254,14 @@ class WidgetWrapperFactory:
12541254
@staticmethod
12551255
def create_wrapper(param, dialog, row=0, col=0):
12561256

1257-
if hasattr(param, 'metadata'):
1257+
if param.metadata().get('widget_wrapper', None) is not None:
12581258
return WidgetWrapperFactory.create_wrapper_from_metadata(param, dialog, row, col)
12591259
else:
12601260
return WidgetWrapperFactory.create_wrapper_from_class(param, dialog, row, col)
12611261

12621262
@staticmethod
12631263
def create_wrapper_from_metadata(param, dialog, row=0, col=0):
1264-
wrapper = param.metadata.get('widget_wrapper', None)
1264+
wrapper = param.metadata().get('widget_wrapper', None)
12651265
params = {}
12661266
# wrapper metadata should be a dict with class key
12671267
if isinstance(wrapper, dict):

0 commit comments

Comments
 (0)