diff options
| author | Paul McMillan <Paul@McMillan.ws> | 2010-08-09 22:11:28 +0000 |
|---|---|---|
| committer | Paul McMillan <Paul@McMillan.ws> | 2010-08-09 22:11:28 +0000 |
| commit | a2e30a41dd00baaa85f0162934327ff0e3dfce51 (patch) | |
| tree | a9a2cc7f7e2c31df860c8b0619c97f65a8273503 /django/core/management/__init__.py | |
| parent | 6c7baa96d84d33c8d02d8899f462255d805d695e (diff) | |
[soc2010/test-refactor] Merged back up to trunk
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2010/test-refactor@13566 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django/core/management/__init__.py')
| -rw-r--r-- | django/core/management/__init__.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/django/core/management/__init__.py b/django/core/management/__init__.py index 32e744374a..85bf324fdc 100644 --- a/django/core/management/__init__.py +++ b/django/core/management/__init__.py @@ -250,15 +250,15 @@ class ManagementUtility(object): """ try: app_name = get_commands()[subcommand] - if isinstance(app_name, BaseCommand): - # If the command is already loaded, use it directly. - klass = app_name - else: - klass = load_command_class(app_name, subcommand) except KeyError: sys.stderr.write("Unknown command: %r\nType '%s help' for usage.\n" % \ (subcommand, self.prog_name)) sys.exit(1) + if isinstance(app_name, BaseCommand): + # If the command is already loaded, use it directly. + klass = app_name + else: + klass = load_command_class(app_name, subcommand) return klass def autocomplete(self): |
