From a3aa5452508e6d4260bd517f31e7cd6611ab3d58 Mon Sep 17 00:00:00 2001 From: Adrian Holovaty Date: Tue, 28 Feb 2006 14:27:00 +0000 Subject: [PATCH] magic-removal: Fixed #1418 -- Applied management.py fixes for 'sqlclear'. Thanks, nesh git-svn-id: http://code.djangoproject.com/svn/django/branches/magic-removal@2442 bcc190cf-cafb-0310-a4f2-bffc1f526a37 --- django/core/management.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/django/core/management.py b/django/core/management.py index ce40375dc8..f6552d0343 100644 --- a/django/core/management.py +++ b/django/core/management.py @@ -297,12 +297,11 @@ def get_sql_delete(app): app_label = app_models[0]._meta.app_label # Delete from django_package, auth_permission, django_content_type. + # TODO: fix this when permissions are activated again + # output.append("DELETE FROM %s WHERE %s = '%s';" % \ + # (backend.quote_name('auth_permission'), backend.quote_name('package'), app_label)) output.append("DELETE FROM %s WHERE %s = '%s';" % \ - (backend.quote_name('django_package'), backend.quote_name('label'), app_label)) - output.append("DELETE FROM %s WHERE %s = '%s';" % \ - (backend.quote_name('auth_permission'), backend.quote_name('package'), app_label)) - output.append("DELETE FROM %s WHERE %s = '%s';" % \ - (backend.quote_name('django_content_type'), backend.quote_name('package'), app_label)) + (backend.quote_name('django_content_type'), backend.quote_name('app_label'), app_label)) # Delete from the admin log. if cursor is not None: