~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/code/security.py

[r=gmb][bug=283167] Branch owners can edit any subscriptions to the
 branch.

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
 
23
23
        Any team member can edit a branch subscription for their team.
24
24
        Launchpad Admins can also edit any branch subscription.
 
25
        The owner of the subscribed branch can edit the subscription. If the
 
26
        branch owner is a team, then members of the team can edit the
 
27
        subscription.
25
28
        """
26
 
        return (user.inTeam(self.obj.person) or
 
29
        return (user.inTeam(self.obj.branch.owner) or
 
30
                user.inTeam(self.obj.person) or
27
31
                user.inTeam(self.obj.subscribed_by) or
28
32
                user.in_admin or
29
33
                user.in_bazaar_experts)
31
35
 
32
36
class BranchSubscriptionView(BranchSubscriptionEdit):
33
37
    permission = 'launchpad.View'
34
 
 
35