From 6fa7ea30fbbfe9fc8b8924d925330547f126721e Mon Sep 17 00:00:00 2001 From: Tomofumi Tanaka Date: Mon, 29 Sep 2014 11:53:19 +0900 Subject: [PATCH] (refs #498)Returns private own repository RepositoryService.getAllRepositories should returns private own repository too. --- src/main/scala/service/RepositoryService.scala | 1 + 1 file changed, 1 insertion(+) diff --git a/src/main/scala/service/RepositoryService.scala b/src/main/scala/service/RepositoryService.scala index 630511656..2a6157fa3 100644 --- a/src/main/scala/service/RepositoryService.scala +++ b/src/main/scala/service/RepositoryService.scala @@ -176,6 +176,7 @@ trait RepositoryService { self: AccountService => def getAllRepositories(userName: String)(implicit s: Session): List[(String, String)] = { Repositories.filter { t1 => (t1.isPrivate === false.bind) || + (t1.userName === userName.bind) || (Collaborators.filter { t2 => t2.byRepository(t1.userName, t1.repositoryName) && (t2.collaboratorName === userName.bind)} exists) }.sortBy(_.lastActivityDate desc).map{ t => (t.userName, t.repositoryName)