Fixed deprecation warning
This commit is contained in:
parent
003454573c
commit
027b3d36de
1 changed files with 1 additions and 1 deletions
|
|
@ -251,7 +251,7 @@ class QuerySet(object):
|
||||||
"""
|
"""
|
||||||
msg = ("get_or_create is scheduled to be deprecated. The approach is "
|
msg = ("get_or_create is scheduled to be deprecated. The approach is "
|
||||||
"flawed without transactions. Upserts should be preferred.")
|
"flawed without transactions. Upserts should be preferred.")
|
||||||
raise DeprecationWarning(msg)
|
warnings.warn(msg, DeprecationWarning)
|
||||||
|
|
||||||
defaults = query.get('defaults', {})
|
defaults = query.get('defaults', {})
|
||||||
if 'defaults' in query:
|
if 'defaults' in query:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue