Skip to content

Commit

Permalink
Fixed #1250 -- Fixed NameError when trying to delete without related …
Browse files Browse the repository at this point in the history
…object permissions in admin interface. Thanks, oggie rob

git-svn-id: http://code.djangoproject.com/svn/django/trunk@2327 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information
adrianholovaty committed Feb 17, 2006
1 parent e9c3efe commit c14e692
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion django/contrib/admin/views/main.py
Expand Up @@ -600,7 +600,7 @@ def _get_deleted_objects(deleted_objects, perms_needed, user, obj, opts, current
if related.opts.admin and has_related_objs:
p = '%s.%s' % (related.opts.app_label, related.opts.get_delete_permission())
if not user.has_perm(p):
perms_needed.add(rel_opts.verbose_name)
perms_needed.add(rel_opts_name)
for related in opts.get_all_related_many_to_many_objects():
if related.opts in opts_seen:
continue
Expand Down

0 comments on commit c14e692

Please sign in to comment.