From 8838d4dd498c8f66ea4237fe8a79a5f77d6f95c9 Mon Sep 17 00:00:00 2001 From: Vytis Banaitis Date: Wed, 1 Feb 2017 18:41:56 +0200 Subject: Refs #23919 -- Replaced kwargs.pop() with keyword-only arguments. --- django/utils/deconstruct.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'django/utils/deconstruct.py') 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) -- cgit v1.3