summaryrefslogtreecommitdiffstats
path: root/src/main/java/com/gitblit/git
diff options
context:
space:
mode:
authorJames Moger <james.moger@gitblit.com>2014-06-08 10:30:39 -0400
committerJames Moger <james.moger@gitblit.com>2014-06-13 08:00:48 -0400
commit6651a8e96bdc51b0c558b88e1c77fcfbed1837da (patch)
treeb2d89a6dd77868783485af61636c65edf32b1861 /src/main/java/com/gitblit/git
parent2bfea381bbcea934f7e20f8c00db86e990c2fc93 (diff)
downloadgitblit-ticket/75.tar.gz
gitblit-ticket/75.zip
Move repository ownership to the UserModel and prepare for project ownershipticket/75
Diffstat (limited to 'src/main/java/com/gitblit/git')
-rw-r--r--src/main/java/com/gitblit/git/GitblitReceivePack.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/com/gitblit/git/GitblitReceivePack.java b/src/main/java/com/gitblit/git/GitblitReceivePack.java
index 34bbea27..0090930a 100644
--- a/src/main/java/com/gitblit/git/GitblitReceivePack.java
+++ b/src/main/java/com/gitblit/git/GitblitReceivePack.java
@@ -286,7 +286,7 @@ public class GitblitReceivePack extends ReceivePack implements PreReceiveHook, P
} else if (ref.equals(BranchTicketService.BRANCH)) {
// ensure pushing user is an administrator OR an owner
// i.e. prevent ticket tampering
- boolean permitted = user.canAdmin() || repository.isOwner(user.username);
+ boolean permitted = user.canAdmin() || user.isOwner(repository);
if (!permitted) {
sendRejection(cmd, "{0} is not permitted to push to {1}", user.username, ref);
}