mirror of
https://github.com/django/django.git
synced 2025-10-27 07:36:08 +00:00
Fixed #13760 -- Cleaned up unnecessary default option handling in a bunch of management commands. Thanks to Paul McMillan for the report and to adamv and Claude Paroz for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17028 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
@@ -22,9 +22,9 @@ class Command(NoArgsCommand):
|
||||
|
||||
def handle_noargs(self, **options):
|
||||
|
||||
verbosity = int(options.get('verbosity', 1))
|
||||
verbosity = int(options.get('verbosity'))
|
||||
interactive = options.get('interactive')
|
||||
show_traceback = options.get('traceback', False)
|
||||
show_traceback = options.get('traceback')
|
||||
|
||||
# Stealth option -- 'load_initial_data' is used by the testing setup
|
||||
# process to disable initial fixture loading.
|
||||
@@ -51,7 +51,7 @@ class Command(NoArgsCommand):
|
||||
if not msg.startswith('No module named') or 'management' not in msg:
|
||||
raise
|
||||
|
||||
db = options.get('database', DEFAULT_DB_ALIAS)
|
||||
db = options.get('database')
|
||||
connection = connections[db]
|
||||
cursor = connection.cursor()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user