diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2023-01-14 02:54:02 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-13 18:54:02 +0000 |
commit | a3ab82e5924196632f1731ae3ef2099bf9d39501 (patch) | |
tree | 7b4f840dae95f4f5b2a3ff11d822e3fdf45016e6 /models/repo | |
parent | 4fc1517da0014ea4414ac51d67b26553c30139a1 (diff) | |
download | gitea-a3ab82e5924196632f1731ae3ef2099bf9d39501.tar.gz gitea-a3ab82e5924196632f1731ae3ef2099bf9d39501.zip |
Fix error when calculate the repository size (#22392)
Fix #22386
`GetDirectorySize` moved as `getDirectorySize` because it becomes a
special function which should not be put in `util`.
Co-authored-by: Jason Song <i@wolfogre.com>
Diffstat (limited to 'models/repo')
-rw-r--r-- | models/repo/update.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/models/repo/update.go b/models/repo/update.go index 3aef280ff8..8dd1097450 100644 --- a/models/repo/update.go +++ b/models/repo/update.go @@ -184,7 +184,7 @@ func ChangeRepositoryName(doer *user_model.User, repo *Repository, newRepoName s return committer.Commit() } -// UpdateRepoSize updates the repository size, calculating it using util.GetDirectorySize +// UpdateRepoSize updates the repository size, calculating it using getDirectorySize func UpdateRepoSize(ctx context.Context, repoID, size int64) error { _, err := db.GetEngine(ctx).ID(repoID).Cols("size").NoAutoTime().Update(&Repository{ Size: size, |