From 590444b27306b6e3b4edd9b3d6aaa8902df878d6 Mon Sep 17 00:00:00 2001 From: Lance Edgar Date: Tue, 25 Oct 2016 18:14:43 -0500 Subject: [PATCH] Fix template bug when deleting user --- tailbone/views/users.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tailbone/views/users.py b/tailbone/views/users.py index 46639179..fc395c62 100644 --- a/tailbone/views/users.py +++ b/tailbone/views/users.py @@ -175,13 +175,14 @@ class UsersView(MasterView): fs.roles, ]) if self.viewing: - del fs.password - del fs.confirm_password permissions = self.request.registry.settings.get('tailbone_permissions', {}) renderer = forms.renderers.PermissionsFieldRenderer(permissions, include_guest=True, include_authenticated=True) fs.append(formalchemy.Field('permissions', renderer=renderer)) + if self.viewing or self.deleting: + del fs.password + del fs.confirm_password class UserVersionView(VersionView):