diff --git a/docs/topics/migrations.txt b/docs/topics/migrations.txt index 1220b4b41f4..b0bc13b32a1 100644 --- a/docs/topics/migrations.txt +++ b/docs/topics/migrations.txt @@ -284,7 +284,7 @@ You can't modify the number of positional arguments in an already migrated custom field without raising a ``TypeError``. The old migration will call the modified ``__init__`` method with the old signature. So if you need a new argument, please create a keyword argument and add something like -``assert kwargs.get('argument_name') is not None`` in the constructor. +``assert 'argument_name' in kwargs`` in the constructor. .. _using-managers-in-migrations: