summaryrefslogtreecommitdiffstats
path: root/modules/repository
diff options
context:
space:
mode:
Diffstat (limited to 'modules/repository')
-rw-r--r--modules/repository/create_test.go4
-rw-r--r--modules/repository/repo.go2
2 files changed, 3 insertions, 3 deletions
diff --git a/modules/repository/create_test.go b/modules/repository/create_test.go
index 293071bdce..e620422bcb 100644
--- a/modules/repository/create_test.go
+++ b/modules/repository/create_test.go
@@ -49,7 +49,7 @@ func TestIncludesAllRepositoriesTeams(t *testing.T) {
assert.NoError(t, organization.CreateOrganization(org, user), "CreateOrganization")
// Check Owner team.
- ownerTeam, err := org.GetOwnerTeam()
+ ownerTeam, err := org.GetOwnerTeam(db.DefaultContext)
assert.NoError(t, err, "GetOwnerTeam")
assert.True(t, ownerTeam.IncludesAllRepositories, "Owner team includes all repositories")
@@ -63,7 +63,7 @@ func TestIncludesAllRepositoriesTeams(t *testing.T) {
}
}
// Get fresh copy of Owner team after creating repos.
- ownerTeam, err = org.GetOwnerTeam()
+ ownerTeam, err = org.GetOwnerTeam(db.DefaultContext)
assert.NoError(t, err, "GetOwnerTeam")
// Create teams and check repositories.
diff --git a/modules/repository/repo.go b/modules/repository/repo.go
index d1a70e7c15..c03e469990 100644
--- a/modules/repository/repo.go
+++ b/modules/repository/repo.go
@@ -57,7 +57,7 @@ func MigrateRepositoryGitData(ctx context.Context, u *user_model.User,
repoPath := repo_model.RepoPath(u.Name, opts.RepoName)
if u.IsOrganization() {
- t, err := organization.OrgFromUser(u).GetOwnerTeam()
+ t, err := organization.OrgFromUser(u).GetOwnerTeam(ctx)
if err != nil {
return nil, err
}