diff options
| author | Vytis Banaitis <vytis.banaitis@gmail.com> | 2017-02-01 18:41:56 +0200 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2017-02-01 11:41:56 -0500 |
| commit | 8838d4dd498c8f66ea4237fe8a79a5f77d6f95c9 (patch) | |
| tree | b75fa27930b8758ad36669b523b084ac09ce290b /django/contrib/gis/geos/libgeos.py | |
| parent | 0ec4dc91e0e7befdd06aa0613b5d0fbe3c785ee7 (diff) | |
Refs #23919 -- Replaced kwargs.pop() with keyword-only arguments.
Diffstat (limited to 'django/contrib/gis/geos/libgeos.py')
| -rw-r--r-- | django/contrib/gis/geos/libgeos.py | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/django/contrib/gis/geos/libgeos.py b/django/contrib/gis/geos/libgeos.py index faf29de0c1..43353e5750 100644 --- a/django/contrib/gis/geos/libgeos.py +++ b/django/contrib/gis/geos/libgeos.py @@ -147,11 +147,14 @@ class GEOSFuncFactory: restype = None errcheck = None - def __init__(self, func_name, *args, **kwargs): + def __init__(self, func_name, *args, restype=None, errcheck=None, argtypes=None, **kwargs): self.func_name = func_name - self.restype = kwargs.pop('restype', self.restype) - self.errcheck = kwargs.pop('errcheck', self.errcheck) - self.argtypes = kwargs.pop('argtypes', self.argtypes) + if restype is not None: + self.restype = restype + if errcheck is not None: + self.errcheck = errcheck + if argtypes is not None: + self.argtypes = argtypes self.args = args self.kwargs = kwargs self.func = None |
