Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 7dfa133

Browse files
committedSep 19, 2017
[processing] Fix type resolving in python field calculator
1 parent ecd2229 commit 7dfa133

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed
 

‎python/plugins/processing/algs/qgis/FieldPyculator.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,8 @@ def processAlgorithm(self, parameters, context, feedback):
9797
globalExpression = self.parameterAsString(parameters, self.GLOBAL, context)
9898

9999
fields = source.fields()
100-
fields.append(QgsField(field_name, self.TYPES[field_type], '',
101-
width, precision))
100+
field = QgsField(field_name, field_type, '', width, precision)
101+
fields.append(field)
102102
new_ns = {}
103103

104104
(sink, dest_id) = self.parameterAsSink(parameters, self.OUTPUT, context,

0 commit comments

Comments
 (0)
Please sign in to comment.