diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2022-06-05 03:18:50 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-04 20:18:50 +0100 |
commit | 12c742f8dc25e4148c44d1265d119c35f161bf74 (patch) | |
tree | 0c35f1de4cf7bdea1dfc8b03468f3616d0c82796 /models/action.go | |
parent | 449ea6005fb613212102126ff267f5c16f7c40b8 (diff) | |
download | gitea-12c742f8dc25e4148c44d1265d119c35f161bf74.tar.gz gitea-12c742f8dc25e4148c44d1265d119c35f161bf74.zip |
Fix order by parameter (#19849)
Upgrade builder to v0.3.11
Upgrade xorm to v1.3.1 and fixed some hidden bugs.
Replace #19821
Replace #19834
Included #19850
Co-authored-by: zeripath <art27@cantab.net>
Diffstat (limited to 'models/action.go')
-rw-r--r-- | models/action.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/models/action.go b/models/action.go index 29e2ea47bd..87bfcbbbad 100644 --- a/models/action.go +++ b/models/action.go @@ -492,7 +492,7 @@ func notifyWatchers(ctx context.Context, actions ...*Action) error { if act.Repo.Owner.IsOrganization() && act.ActUserID != act.Repo.Owner.ID { act.ID = 0 act.UserID = act.Repo.Owner.ID - if _, err = e.InsertOne(act); err != nil { + if err = db.Insert(ctx, act); err != nil { return fmt.Errorf("insert new actioner: %v", err) } } @@ -545,7 +545,7 @@ func notifyWatchers(ctx context.Context, actions ...*Action) error { } } - if _, err = e.InsertOne(act); err != nil { + if err = db.Insert(ctx, act); err != nil { return fmt.Errorf("insert new action: %v", err) } } |