# HG changeset patch # User Mads Kiilerich # Date 2020-04-10 13:29:48 # Node ID de0f50a7b86a6ee468e1c57fe4cdf1c997254626 # Parent 84487755bb2e48ef6a744cebe01fb1f217547325 py3: fix display of default user permissions Avoid http://localhost:5000/vcs_test_hg/settings/permissions with explicit user permissions failing: TypeError: '<' not supported between instances of 'str' and 'bool' diff --git a/kallithea/templates/admin/repos/repo_edit_permissions.html b/kallithea/templates/admin/repos/repo_edit_permissions.html --- a/kallithea/templates/admin/repos/repo_edit_permissions.html +++ b/kallithea/templates/admin/repos/repo_edit_permissions.html @@ -12,7 +12,7 @@ ## USERS - %for r2p in sorted(c.repo_info.repo_to_perm, key=lambda x: x.user.username != 'default' and x.user.username): + %for r2p in sorted(c.repo_info.repo_to_perm, key=lambda x: '' if x.user.username == 'default' else x.user.username): %if r2p.user.username =='default' and c.repo_info.private: