summaryrefslogtreecommitdiff
path: root/django/db/backends/base
diff options
context:
space:
mode:
authorДилян Палаузов <dilyanpalauzov@users.noreply.github.com>2017-11-06 10:23:29 -0500
committerTim Graham <timograham@gmail.com>2017-11-07 09:08:46 -0500
commitc69e4bc69166b2d752b437a651dfa91f8b53ecfd (patch)
tree49cb2c1b54962eff1a02636062b213397003e7ed /django/db/backends/base
parent00b93c2b1ecdda978f067309c6feafda633a7264 (diff)
Fixed #28769 -- Replaced 'x if x else y' with 'x or y'.
Diffstat (limited to 'django/db/backends/base')
-rw-r--r--django/db/backends/base/introspection.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/django/db/backends/base/introspection.py b/django/db/backends/base/introspection.py
index 27a3cb2b87..154ae22bf1 100644
--- a/django/db/backends/base/introspection.py
+++ b/django/db/backends/base/introspection.py
@@ -130,7 +130,7 @@ class BaseDatabaseIntrospection:
# we don't need to reset the sequence.
if f.remote_field.through is None:
sequence = self.get_sequences(cursor, f.m2m_db_table())
- sequence_list.extend(sequence if sequence else [{'table': f.m2m_db_table(), 'column': None}])
+ sequence_list.extend(sequence or [{'table': f.m2m_db_table(), 'column': None}])
return sequence_list
def get_sequences(self, cursor, table_name, table_fields=()):