aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--models/repo/repo.go9
1 files changed, 8 insertions, 1 deletions
diff --git a/models/repo/repo.go b/models/repo/repo.go
index 28d976773d..156ead405d 100644
--- a/models/repo/repo.go
+++ b/models/repo/repo.go
@@ -290,7 +290,14 @@ func (repo *Repository) LoadUnits(ctx context.Context) (err error) {
}
repo.Units, err = getUnitsByRepoID(db.GetEngine(ctx), repo.ID)
- log.Trace("repo.Units: %-+v", repo.Units)
+ if log.IsTrace() {
+ unitTypeStrings := make([]string, len(repo.Units))
+ for i, unit := range repo.Units {
+ unitTypeStrings[i] = unit.Type.String()
+ }
+ log.Trace("repo.Units, ID=%d, Types: [%s]", repo.ID, strings.Join(unitTypeStrings, ", "))
+ }
+
return err
}