summaryrefslogtreecommitdiff
path: root/django/core/management/commands/loaddata.py
diff options
context:
space:
mode:
Diffstat (limited to 'django/core/management/commands/loaddata.py')
-rw-r--r--django/core/management/commands/loaddata.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/django/core/management/commands/loaddata.py b/django/core/management/commands/loaddata.py
index 4967c64cd2..598c98cd6a 100644
--- a/django/core/management/commands/loaddata.py
+++ b/django/core/management/commands/loaddata.py
@@ -36,7 +36,7 @@ class Command(BaseCommand):
)
def handle(self, *fixture_labels, **options):
- using = options['database']
+ using = options.get('database', DEFAULT_DB_ALIAS)
excluded_apps = options.get('exclude', [])
connection = connections[using]