Use geometry by default on custom expression functions

Got burnt by my own code. Them feels.
This commit is contained in:
Nathan Woodrow 2015-12-09 13:02:56 +10:00
parent 6e140b97fd
commit e9ef51341c

View File

@ -39,7 +39,7 @@ def register_function(function, arg_count, group, usesgeometry=False, **kwargs):
"""
class QgsExpressionFunction(QgsExpression.Function):
def __init__(self, func, name, args, group, helptext='', usesgeometry=False, expandargs=False):
def __init__(self, func, name, args, group, helptext='', usesgeometry=True, expandargs=False):
QgsExpression.Function.__init__(self, name, args, group, helptext, usesgeometry)
self.function = func
self.expandargs = expandargs