Skip to content
Browse files

magic-removal: Fixed #1418 -- Applied management.py fixes for 'sqlcle…

…ar'. Thanks, nesh

git-svn-id: http://code.djangoproject.com/svn/django/branches/magic-removal@2442 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
1 parent 18d1b81 commit a3aa5452508e6d4260bd517f31e7cd6611ab3d58 @adrianholovaty adrianholovaty committed
Showing with 4 additions and 5 deletions.
  1. +4 −5 django/core/management.py
View
9 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:

0 comments on commit a3aa545

Please sign in to comment.
Something went wrong with that request. Please try again.