comparison MoinMoin/groups/backends/config_group.py @ 4803:167db6117bb4

Groups2009: pep8 fixes and typo elimination. BaseGroup._iter optimization. Test of group names mapping was removed.
author Dmitrijs Milajevs <dimazest@gmail.com>
date Thu, 11 Jun 2009 13:48:54 +0200
parents 3b05bf18c0d1
children 6a109416e2b2
comparison
equal deleted inserted replaced
4802:878b5a87ba3b 4803:167db6117bb4
1 # -*- coding: iso-8859-1 -*- 1 # -*- coding: iso-8859-1 -*-
2 """ 2 """
3 MoinMoin - config group backend 3 MoinMoin - config group backend
4 4
5 The wiki group backend enables you to define groups in a configuration file. 5 The config group backend enables you to define groups in a configuration file.
6 6
7 @copyright: 2009 MoinMoin:DmitrijsMilajevs 7 @copyright: 2009 MoinMoin:DmitrijsMilajevs
8 @license: GPL, see COPYING for details 8 @license: GPL, see COPYING for details
9 """ 9 """
10 10
11 from MoinMoin.groups.backends import BaseGroup, BaseBackend 11 from MoinMoin.groups.backends import BaseGroup, BaseBackend
12 12
13
13 class Group(BaseGroup): 14 class Group(BaseGroup):
15
14 def _load_group(self): 16 def _load_group(self):
15 request = self.request 17 request = self.request
16 backend_group_name = self.to_backend_name(self.name) 18 backend_group_name = self.to_backend_name(self.name)
17 19
18 members_final = set() 20 members_final = set()
24 else: 26 else:
25 members_final.add(member) 27 members_final.add(member)
26 28
27 self.members = members_final 29 self.members = members_final
28 self.member_groups = member_groups 30 self.member_groups = member_groups
31
29 32
30 class Backend(BaseBackend): 33 class Backend(BaseBackend):
31 34
32 def __init__(self, request, groups=None): 35 def __init__(self, request, groups=None):
33 """ 36 """