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/utils/deconstruct.py | |
parent | 0ec4dc91e0e7befdd06aa0613b5d0fbe3c785ee7 (diff) | |
download | django-8838d4dd498c8f66ea4237fe8a79a5f77d6f95c9.tar.gz |
Refs #23919 -- Replaced kwargs.pop() with keyword-only arguments.
Diffstat (limited to 'django/utils/deconstruct.py')
-rw-r--r-- | django/utils/deconstruct.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/django/utils/deconstruct.py b/django/utils/deconstruct.py index 6bc70f7e53..c546fc1dea 100644 --- a/django/utils/deconstruct.py +++ b/django/utils/deconstruct.py @@ -3,15 +3,13 @@ from importlib import import_module from django.utils.version import get_docs_version -def deconstructible(*args, **kwargs): +def deconstructible(*args, path=None): """ Class decorator that allow the decorated class to be serialized by the migrations subsystem. Accepts an optional kwarg `path` to specify the import path. """ - path = kwargs.pop('path', None) - def decorator(klass): def __new__(cls, *args, **kwargs): # We capture the arguments to make returning them trivial @@ -54,4 +52,4 @@ def deconstructible(*args, **kwargs): if not args: return decorator - return decorator(*args, **kwargs) + return decorator(*args) |