Skip to content

Commit 016c2f3

Browse files
authored
Merge branch 'go-gitea:main' into main
2 parents c6acfc1 + 355e9a9 commit 016c2f3

File tree

27 files changed

+280
-68
lines changed

27 files changed

+280
-68
lines changed

models/actions/run.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,7 @@ func (run *ActionRun) IsSchedule() bool {
171171

172172
func updateRepoRunsNumbers(ctx context.Context, repo *repo_model.Repository) error {
173173
_, err := db.GetEngine(ctx).ID(repo.ID).
174+
NoAutoTime().
174175
SetExpr("num_action_runs",
175176
builder.Select("count(*)").From("action_run").
176177
Where(builder.Eq{"repo_id": repo.ID}),

models/repo/transfer.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ func CreatePendingRepositoryTransfer(ctx context.Context, doer, newOwner *user_m
249249
}
250250

251251
repo.Status = RepositoryPendingTransfer
252-
if err := UpdateRepositoryCols(ctx, repo, "status"); err != nil {
252+
if err := UpdateRepositoryColsNoAutoTime(ctx, repo, "status"); err != nil {
253253
return err
254254
}
255255

models/repo/update.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ func UpdateRepositoryOwnerNames(ctx context.Context, ownerID int64, ownerName st
2525
}
2626
defer committer.Close()
2727

28-
if _, err := db.GetEngine(ctx).Where("owner_id = ?", ownerID).Cols("owner_name").Update(&Repository{
28+
if _, err := db.GetEngine(ctx).Where("owner_id = ?", ownerID).Cols("owner_name").NoAutoTime().Update(&Repository{
2929
OwnerName: ownerName,
3030
}); err != nil {
3131
return err
@@ -40,8 +40,8 @@ func UpdateRepositoryUpdatedTime(ctx context.Context, repoID int64, updateTime t
4040
return err
4141
}
4242

43-
// UpdateRepositoryCols updates repository's columns
44-
func UpdateRepositoryCols(ctx context.Context, repo *Repository, cols ...string) error {
43+
// UpdateRepositoryColsWithAutoTime updates repository's columns
44+
func UpdateRepositoryColsWithAutoTime(ctx context.Context, repo *Repository, cols ...string) error {
4545
_, err := db.GetEngine(ctx).ID(repo.ID).Cols(cols...).Update(repo)
4646
return err
4747
}

options/locale/locale_zh-CN.ini

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,7 @@ files=文件
117117

118118
error=错误
119119
error404=您正尝试访问的页面 <strong>不存在</strong> 或 <strong>您尚未被授权</strong> 查看该页面。
120+
error503=服务器无法完成您的请求,请稍后重试。
120121
go_back=返回
121122
invalid_data=无效数据: %v
122123

@@ -129,6 +130,7 @@ pin=固定
129130
unpin=取消置顶
130131

131132
artifacts=制品
133+
expired=已过期
132134
confirm_delete_artifact=您确定要删除制品'%s'吗?
133135

134136
archived=已归档
@@ -449,6 +451,7 @@ use_scratch_code=使用验证口令
449451
twofa_scratch_used=你已经使用了你的验证口令。你将会转到两步验证设置页面以便移除你的注册设备或者重新生成新的验证口令。
450452
twofa_passcode_incorrect=你的验证码不正确。如果你丢失了你的设备,请使用你的验证口令。
451453
twofa_scratch_token_incorrect=你的验证口令不正确。
454+
twofa_required=您必须设置两步验证来访问仓库,或者尝试重新登录。
452455
login_userpass=登录
453456
login_openid=OpenID
454457
oauth_signup_tab=注册帐号
@@ -1524,7 +1527,7 @@ issues.move_to_column_of_project=`将此对象移至 %s 的 %s 中在 %s 上`
15241527
issues.change_milestone_at=`%[3]s 修改了里程碑从 <b>%[1]s</b> 到 <b>%[2]s</b>`
15251528
issues.change_project_at=于 %[3]s 将此从项目 <b>%[1]s</b> 移到 <b>%[2]s</b>
15261529
issues.remove_milestone_at=`%[2]s 删除了里程碑 <b>%[1]s</b>`
1527-
issues.remove_project_at=`<b>%s</b> 项目 %s 中删除`
1530+
issues.remove_project_at=`于 %[2]s 将此工单从项目 <b>%[1]s</b> 中删除`
15281531
issues.deleted_milestone=(已删除)
15291532
issues.deleted_project=`(已删除)`
15301533
issues.self_assign_at=`于 %s 指派给自己`
@@ -1877,6 +1880,7 @@ pulls.add_prefix=添加 <strong>%s</strong> 前缀
18771880
pulls.remove_prefix=删除 <strong>%s</strong> 前缀
18781881
pulls.data_broken=此合并请求因为派生仓库信息缺失而中断。
18791882
pulls.files_conflicted=此合并请求有变更与目标分支冲突。
1883+
pulls.is_checking=正在进行合并冲突检测 ...
18801884
pulls.is_ancestor=此分支已经包含在目标分支中,没有什么可以合并。
18811885
pulls.is_empty=此分支上的更改已经在目标分支上。这将是一个空提交。
18821886
pulls.required_status_check_failed=一些必要的检查没有成功
@@ -3724,7 +3728,11 @@ creation.name_placeholder=不区分大小写,字母数字或下划线不能以
37243728
creation.value_placeholder=输入任何内容,开头和结尾的空白都会被省略
37253729
creation.description_placeholder=输入简短描述(可选)。
37263730

3731+
save_success=密钥 '%s' 保存成功。
3732+
save_failed=密钥保存失败。
37273733

3734+
add_secret=添加密钥
3735+
edit_secret=编辑密钥
37283736
deletion=删除密钥
37293737
deletion.description=删除密钥是永久性的,无法撤消。继续吗?
37303738
deletion.success=此Secret已被删除。
@@ -3841,6 +3849,8 @@ deleted.display_name=已删除项目
38413849
type-1.display_name=个人项目
38423850
type-2.display_name=仓库项目
38433851
type-3.display_name=组织项目
3852+
enter_fullscreen=全屏
3853+
exit_fullscreen=退出全屏
38443854

38453855
[git.filemode]
38463856
changed_filemode=%[1]s -> %[2]s

routers/api/v1/repo/issue.go

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -895,6 +895,15 @@ func EditIssue(ctx *context.APIContext) {
895895
issue.MilestoneID != *form.Milestone {
896896
oldMilestoneID := issue.MilestoneID
897897
issue.MilestoneID = *form.Milestone
898+
if issue.MilestoneID > 0 {
899+
issue.Milestone, err = issues_model.GetMilestoneByRepoID(ctx, ctx.Repo.Repository.ID, *form.Milestone)
900+
if err != nil {
901+
ctx.APIErrorInternal(err)
902+
return
903+
}
904+
} else {
905+
issue.Milestone = nil
906+
}
898907
if err = issue_service.ChangeMilestoneAssign(ctx, issue, ctx.Doer, oldMilestoneID); err != nil {
899908
ctx.APIErrorInternal(err)
900909
return

routers/api/v1/repo/issue_comment.go

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -609,15 +609,17 @@ func editIssueComment(ctx *context.APIContext, form api.EditIssueCommentOption)
609609
return
610610
}
611611

612-
oldContent := comment.Content
613-
comment.Content = form.Body
614-
if err := issue_service.UpdateComment(ctx, comment, comment.ContentVersion, ctx.Doer, oldContent); err != nil {
615-
if errors.Is(err, user_model.ErrBlockedUser) {
616-
ctx.APIError(http.StatusForbidden, err)
617-
} else {
618-
ctx.APIErrorInternal(err)
612+
if form.Body != comment.Content {
613+
oldContent := comment.Content
614+
comment.Content = form.Body
615+
if err := issue_service.UpdateComment(ctx, comment, comment.ContentVersion, ctx.Doer, oldContent); err != nil {
616+
if errors.Is(err, user_model.ErrBlockedUser) {
617+
ctx.APIError(http.StatusForbidden, err)
618+
} else {
619+
ctx.APIErrorInternal(err)
620+
}
621+
return
619622
}
620-
return
621623
}
622624

623625
ctx.JSON(http.StatusOK, convert.ToAPIComment(ctx, ctx.Repo.Repository, comment))

routers/api/v1/repo/pull.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -706,6 +706,11 @@ func EditPullRequest(ctx *context.APIContext) {
706706
issue.MilestoneID != form.Milestone {
707707
oldMilestoneID := issue.MilestoneID
708708
issue.MilestoneID = form.Milestone
709+
issue.Milestone, err = issues_model.GetMilestoneByRepoID(ctx, ctx.Repo.Repository.ID, form.Milestone)
710+
if err != nil {
711+
ctx.APIErrorInternal(err)
712+
return
713+
}
709714
if err = issue_service.ChangeMilestoneAssign(ctx, issue, ctx.Doer, oldMilestoneID); err != nil {
710715
ctx.APIErrorInternal(err)
711716
return

routers/private/hook_post_receive.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ func HookPostReceive(ctx *gitea_context.PrivateContext) {
220220
}
221221

222222
if len(cols) > 0 {
223-
if err := repo_model.UpdateRepositoryCols(ctx, repo, cols...); err != nil {
223+
if err := repo_model.UpdateRepositoryColsNoAutoTime(ctx, repo, cols...); err != nil {
224224
log.Error("Failed to Update: %s/%s Error: %v", ownerName, repoName, err)
225225
ctx.JSON(http.StatusInternalServerError, private.HookPostReceiveResult{
226226
Err: fmt.Sprintf("Failed to Update: %s/%s Error: %v", ownerName, repoName, err),

routers/web/repo/editor.go

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -376,12 +376,6 @@ func editFilePost(ctx *context.Context, form forms.EditRepoFileForm, isNewFile b
376376
}
377377
}
378378

379-
if ctx.Repo.Repository.IsEmpty {
380-
if isEmpty, err := ctx.Repo.GitRepo.IsEmpty(); err == nil && !isEmpty {
381-
_ = repo_model.UpdateRepositoryCols(ctx, &repo_model.Repository{ID: ctx.Repo.Repository.ID, IsEmpty: false}, "is_empty")
382-
}
383-
}
384-
385379
redirectForCommitChoice(ctx, form.CommitChoice, branchName, form.TreePath)
386380
}
387381

@@ -790,7 +784,7 @@ func UploadFilePost(ctx *context.Context) {
790784

791785
if ctx.Repo.Repository.IsEmpty {
792786
if isEmpty, err := ctx.Repo.GitRepo.IsEmpty(); err == nil && !isEmpty {
793-
_ = repo_model.UpdateRepositoryCols(ctx, &repo_model.Repository{ID: ctx.Repo.Repository.ID, IsEmpty: false}, "is_empty")
787+
_ = repo_model.UpdateRepositoryColsWithAutoTime(ctx, &repo_model.Repository{ID: ctx.Repo.Repository.ID, IsEmpty: false}, "is_empty")
794788
}
795789
}
796790

routers/web/repo/issue.go

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -418,6 +418,16 @@ func UpdateIssueMilestone(ctx *context.Context) {
418418
continue
419419
}
420420
issue.MilestoneID = milestoneID
421+
if milestoneID > 0 {
422+
var err error
423+
issue.Milestone, err = issues_model.GetMilestoneByRepoID(ctx, ctx.Repo.Repository.ID, milestoneID)
424+
if err != nil {
425+
ctx.ServerError("GetMilestoneByRepoID", err)
426+
return
427+
}
428+
} else {
429+
issue.Milestone = nil
430+
}
421431
if err := issue_service.ChangeMilestoneAssign(ctx, issue, ctx.Doer, oldMilestoneID); err != nil {
422432
ctx.ServerError("ChangeMilestoneAssign", err)
423433
return

routers/web/repo/issue_comment.go

Lines changed: 18 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -239,21 +239,28 @@ func UpdateCommentContent(ctx *context.Context) {
239239
return
240240
}
241241

242-
oldContent := comment.Content
243242
newContent := ctx.FormString("content")
244243
contentVersion := ctx.FormInt("content_version")
244+
if contentVersion != comment.ContentVersion {
245+
ctx.JSONError(ctx.Tr("repo.comments.edit.already_changed"))
246+
return
247+
}
245248

246-
// allow to save empty content
247-
comment.Content = newContent
248-
if err = issue_service.UpdateComment(ctx, comment, contentVersion, ctx.Doer, oldContent); err != nil {
249-
if errors.Is(err, user_model.ErrBlockedUser) {
250-
ctx.JSONError(ctx.Tr("repo.issues.comment.blocked_user"))
251-
} else if errors.Is(err, issues_model.ErrCommentAlreadyChanged) {
252-
ctx.JSONError(ctx.Tr("repo.comments.edit.already_changed"))
253-
} else {
254-
ctx.ServerError("UpdateComment", err)
249+
if newContent != comment.Content {
250+
// allow to save empty content
251+
oldContent := comment.Content
252+
comment.Content = newContent
253+
254+
if err = issue_service.UpdateComment(ctx, comment, contentVersion, ctx.Doer, oldContent); err != nil {
255+
if errors.Is(err, user_model.ErrBlockedUser) {
256+
ctx.JSONError(ctx.Tr("repo.issues.comment.blocked_user"))
257+
} else if errors.Is(err, issues_model.ErrCommentAlreadyChanged) {
258+
ctx.JSONError(ctx.Tr("repo.comments.edit.already_changed"))
259+
} else {
260+
ctx.ServerError("UpdateComment", err)
261+
}
262+
return
255263
}
256-
return
257264
}
258265

259266
if err := comment.LoadAttachments(ctx); err != nil {

routers/web/repo/wiki.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ func findWikiRepoCommit(ctx *context.Context) (*git.Repository, *git.Commit, err
109109
return wikiGitRepo, nil, errBranch
110110
}
111111
// update the default branch in the database
112-
errDb := repo_model.UpdateRepositoryCols(ctx, &repo_model.Repository{ID: ctx.Repo.Repository.ID, DefaultWikiBranch: gitRepoDefaultBranch}, "default_wiki_branch")
112+
errDb := repo_model.UpdateRepositoryColsNoAutoTime(ctx, &repo_model.Repository{ID: ctx.Repo.Repository.ID, DefaultWikiBranch: gitRepoDefaultBranch}, "default_wiki_branch")
113113
if errDb != nil {
114114
return wikiGitRepo, nil, errDb
115115
}

routers/web/repo/wiki_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@ func TestDefaultWikiBranch(t *testing.T) {
245245
assert.NoError(t, wiki_service.ChangeDefaultWikiBranch(db.DefaultContext, repoWithNoWiki, "main"))
246246

247247
// repo with wiki
248-
assert.NoError(t, repo_model.UpdateRepositoryCols(db.DefaultContext, &repo_model.Repository{ID: 1, DefaultWikiBranch: "wrong-branch"}))
248+
assert.NoError(t, repo_model.UpdateRepositoryColsNoAutoTime(db.DefaultContext, &repo_model.Repository{ID: 1, DefaultWikiBranch: "wrong-branch"}))
249249

250250
ctx, _ := contexttest.MockContext(t, "user2/repo1/wiki")
251251
ctx.SetPathParam("*", "Home")

services/migrations/gitea_uploader.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ func (g *GiteaLocalUploader) CreateRepo(ctx context.Context, repo *base.Reposito
148148
return err
149149
}
150150
g.repo.ObjectFormatName = objectFormat.Name()
151-
return repo_model.UpdateRepositoryCols(ctx, g.repo, "object_format_name")
151+
return repo_model.UpdateRepositoryColsNoAutoTime(ctx, g.repo, "object_format_name")
152152
}
153153

154154
// Close closes this uploader
@@ -975,7 +975,7 @@ func (g *GiteaLocalUploader) Finish(ctx context.Context) error {
975975
}
976976

977977
g.repo.Status = repo_model.RepositoryReady
978-
return repo_model.UpdateRepositoryCols(ctx, g.repo, "status")
978+
return repo_model.UpdateRepositoryColsWithAutoTime(ctx, g.repo, "status")
979979
}
980980

981981
func (g *GiteaLocalUploader) remapUser(ctx context.Context, source user_model.ExternalUserMigrated, target user_model.ExternalUserRemappable) error {

services/mirror/mirror_pull.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ func UpdateAddress(ctx context.Context, m *repo_model.Mirror, addr string) error
7171
// erase authentication before storing in database
7272
u.User = nil
7373
m.Repo.OriginalURL = u.String()
74-
return repo_model.UpdateRepositoryCols(ctx, m.Repo, "original_url")
74+
return repo_model.UpdateRepositoryColsNoAutoTime(ctx, m.Repo, "original_url")
7575
}
7676

7777
// mirrorSyncResult contains information of a updated reference.
@@ -653,7 +653,7 @@ func checkAndUpdateEmptyRepository(ctx context.Context, m *repo_model.Mirror, re
653653
}
654654
m.Repo.IsEmpty = false
655655
// Update the is empty and default_branch columns
656-
if err := repo_model.UpdateRepositoryCols(ctx, m.Repo, "default_branch", "is_empty"); err != nil {
656+
if err := repo_model.UpdateRepositoryColsWithAutoTime(ctx, m.Repo, "default_branch", "is_empty"); err != nil {
657657
log.Error("Failed to update default branch of repository %-v. Error: %v", m.Repo, err)
658658
desc := fmt.Sprintf("Failed to update default branch of repository '%s': %v", m.Repo.RepoPath(), err)
659659
if err = system_model.CreateRepositoryNotice(desc); err != nil {

services/repository/adopt.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ func AdoptRepository(ctx context.Context, doer, owner *user_model.User, opts Cre
100100

101101
// 4 - update repository status
102102
repo.Status = repo_model.RepositoryReady
103-
if err = repo_model.UpdateRepositoryCols(ctx, repo, "status"); err != nil {
103+
if err = repo_model.UpdateRepositoryColsWithAutoTime(ctx, repo, "status"); err != nil {
104104
return nil, fmt.Errorf("UpdateRepositoryCols: %w", err)
105105
}
106106

services/repository/avatar.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ func UploadAvatar(ctx context.Context, repo *repo_model.Repository, data []byte)
4040
// Users can upload the same image to other repo - prefix it with ID
4141
// Then repo will be removed - only it avatar file will be removed
4242
repo.Avatar = newAvatar
43-
if err := repo_model.UpdateRepositoryCols(ctx, repo, "avatar"); err != nil {
43+
if err := repo_model.UpdateRepositoryColsNoAutoTime(ctx, repo, "avatar"); err != nil {
4444
return fmt.Errorf("UploadAvatar: Update repository avatar: %w", err)
4545
}
4646

@@ -77,7 +77,7 @@ func DeleteAvatar(ctx context.Context, repo *repo_model.Repository) error {
7777
defer committer.Close()
7878

7979
repo.Avatar = ""
80-
if err := repo_model.UpdateRepositoryCols(ctx, repo, "avatar"); err != nil {
80+
if err := repo_model.UpdateRepositoryColsNoAutoTime(ctx, repo, "avatar"); err != nil {
8181
return fmt.Errorf("DeleteAvatar: Update repository avatar: %w", err)
8282
}
8383

@@ -112,5 +112,5 @@ func generateAvatar(ctx context.Context, templateRepo, generateRepo *repo_model.
112112
return err
113113
}
114114

115-
return repo_model.UpdateRepositoryCols(ctx, generateRepo, "avatar")
115+
return repo_model.UpdateRepositoryColsNoAutoTime(ctx, generateRepo, "avatar")
116116
}

services/repository/create.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -321,7 +321,7 @@ func CreateRepositoryDirectly(ctx context.Context, doer, owner *user_model.User,
321321
// 7 - update repository status to be ready
322322
if needsUpdateToReady {
323323
repo.Status = repo_model.RepositoryReady
324-
if err = repo_model.UpdateRepositoryCols(ctx, repo, "status"); err != nil {
324+
if err = repo_model.UpdateRepositoryColsWithAutoTime(ctx, repo, "status"); err != nil {
325325
return nil, fmt.Errorf("UpdateRepositoryCols: %w", err)
326326
}
327327
}

services/repository/files/update.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ func ChangeRepoFiles(ctx context.Context, repo *repo_model.Repository, doer *use
306306

307307
if repo.IsEmpty {
308308
if isEmpty, err := gitRepo.IsEmpty(); err == nil && !isEmpty {
309-
_ = repo_model.UpdateRepositoryCols(ctx, &repo_model.Repository{ID: repo.ID, IsEmpty: false, DefaultBranch: opts.NewBranch}, "is_empty", "default_branch")
309+
_ = repo_model.UpdateRepositoryColsWithAutoTime(ctx, &repo_model.Repository{ID: repo.ID, IsEmpty: false, DefaultBranch: opts.NewBranch}, "is_empty", "default_branch")
310310
}
311311
}
312312

services/repository/fork.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ func ForkRepository(ctx context.Context, doer, owner *user_model.User, opts Fork
198198

199199
// 8 - update repository status to be ready
200200
repo.Status = repo_model.RepositoryReady
201-
if err = repo_model.UpdateRepositoryCols(ctx, repo, "status"); err != nil {
201+
if err = repo_model.UpdateRepositoryColsWithAutoTime(ctx, repo, "status"); err != nil {
202202
return nil, fmt.Errorf("UpdateRepositoryCols: %w", err)
203203
}
204204

services/repository/push.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ func pushNewBranch(ctx context.Context, repo *repo_model.Repository, pusher *use
283283
}
284284
}
285285
// Update the is empty and default_branch columns
286-
if err := repo_model.UpdateRepositoryCols(ctx, repo, "default_branch", "is_empty"); err != nil {
286+
if err := repo_model.UpdateRepositoryColsWithAutoTime(ctx, repo, "default_branch", "is_empty"); err != nil {
287287
return nil, fmt.Errorf("UpdateRepositoryCols: %w", err)
288288
}
289289
}

services/repository/repository.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ func updateRepository(ctx context.Context, repo *repo_model.Repository, visibili
205205

206206
e := db.GetEngine(ctx)
207207

208-
if _, err = e.ID(repo.ID).AllCols().Update(repo); err != nil {
208+
if _, err = e.ID(repo.ID).NoAutoTime().AllCols().Update(repo); err != nil {
209209
return fmt.Errorf("update: %w", err)
210210
}
211211

services/repository/template.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ func GenerateRepository(ctx context.Context, doer, owner *user_model.User, templ
184184

185185
// 6 - update repository status to be ready
186186
generateRepo.Status = repo_model.RepositoryReady
187-
if err = repo_model.UpdateRepositoryCols(ctx, generateRepo, "status"); err != nil {
187+
if err = repo_model.UpdateRepositoryColsWithAutoTime(ctx, generateRepo, "status"); err != nil {
188188
return nil, fmt.Errorf("UpdateRepositoryCols: %w", err)
189189
}
190190

0 commit comments

Comments
 (0)