rmrepo alternative 2 was too lax
it would have allowed deleting a non-wild repo too! Fixed.
This commit is contained in:
parent
5188ec48ed
commit
07d07cc5f6
|
@ -13,6 +13,8 @@ get_rights_and_owner $delete
|
||||||
|
|
||||||
# alternative 2 -- creator or anyone with W access to admin repo can delete
|
# alternative 2 -- creator or anyone with W access to admin repo can delete
|
||||||
[ "$owner" = "$GL_USER" ] || {
|
[ "$owner" = "$GL_USER" ] || {
|
||||||
|
# but only if it is wild
|
||||||
|
[ "$owner" = "<gitolite>" ] && die "$delete is not a wild repo"
|
||||||
get_rights_and_owner gitolite-admin
|
get_rights_and_owner gitolite-admin
|
||||||
[ -z "$perm_write" ] && die "$delete is not yours to delete and you're not the admin"
|
[ -z "$perm_write" ] && die "$delete is not yours to delete and you're not the admin"
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue