From 1938e51baa37fc68dc423ab5c29f5ea9c2f58ab3 Mon Sep 17 00:00:00 2001 From: "jrayhawk+piny.be@omgwallhack.org" Date: Tue, 1 May 2012 22:04:04 -0700 Subject: Adding check for UID 0 to pinyadmin commands so root can actually do things --- pinyadmin/sbin/addaccess | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'pinyadmin/sbin/addaccess') diff --git a/pinyadmin/sbin/addaccess b/pinyadmin/sbin/addaccess index e351114..557ed15 100755 --- a/pinyadmin/sbin/addaccess +++ b/pinyadmin/sbin/addaccess @@ -11,7 +11,7 @@ my ( $reponame, @users ) = @ARGV; my $repo = Piny::Repo->new( $reponame ); -if ( $repo->owner->uid != $env->user->uid ) { +if ( $env->user->uid != 0 and $repo->owner->uid != $env->user->uid ) { print "You are not the owner of that repo!\n"; exit( 3 ); }; -- cgit v1.2.3