diff options
Diffstat (limited to 'models/fixture_generation.go')
-rw-r--r-- | models/fixture_generation.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/models/fixture_generation.go b/models/fixture_generation.go index 49cf5ad6a6..c87909d01b 100644 --- a/models/fixture_generation.go +++ b/models/fixture_generation.go @@ -15,7 +15,7 @@ import ( // for the access table, as recalculated using repo.RecalculateAccesses() func GetYamlFixturesAccess() (string, error) { repos := make([]*Repository, 0, 50) - if err := db.DefaultContext().Engine().Find(&repos); err != nil { + if err := db.GetEngine(db.DefaultContext).Find(&repos); err != nil { return "", err } @@ -29,7 +29,7 @@ func GetYamlFixturesAccess() (string, error) { var b strings.Builder accesses := make([]*Access, 0, 200) - if err := db.DefaultContext().Engine().OrderBy("user_id, repo_id").Find(&accesses); err != nil { + if err := db.GetEngine(db.DefaultContext).OrderBy("user_id, repo_id").Find(&accesses); err != nil { return "", err } |