You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gitea/services
delvh 778ad795fd
Refactor deletion (#28610)
Introduce the new generic deletion methods
- `func DeleteByID[T any](ctx context.Context, id int64) (int64, error)`
- `func DeleteByIDs[T any](ctx context.Context, ids ...int64) error`
- `func Delete[T any](ctx context.Context, opts FindOptions) (int64,
error)`

So, we no longer need any specific deletion method and can just use
the generic ones instead.

Replacement of #28450

Closes #28450

---------

Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
1 year ago
..
actions Improve ObjectFormat interface (#28496) 1 year ago
agit Adjust object format interface (#28469) 1 year ago
asymkey Refactor deletion (#28610) 1 year ago
attachment Even more `db.DefaultContext` refactor (#27352) 1 year ago
auth Deprecate query string auth tokens (#28390) 1 year ago
automerge Improve queue and logger context (#24924) 2 years ago
context Another round of `db.DefaultContext` refactor (#27103) 1 year ago
convert Adjust object format interface (#28469) 1 year ago
cron Update go dependencies (#28518) 1 year ago
externalaccount Final round of `db.DefaultContext` refactor (#27587) 1 year ago
feed More `db.DefaultContext` refactor (#27265) 1 year ago
forms Adjust object format interface (#28469) 1 year ago
gitdiff Add option to disable ambiguous unicode characters detection (#28454) 1 year ago
indexer Fix missing issue search index update when changing status (#28325) 1 year ago
issue Remove deadcode under models/issues (#28536) 1 year ago
lfs Remove GetByBean method because sometimes it's danger when query condition parameter is zero and also introduce new generic methods (#28220) 1 year ago
mailer Fix missing mail reply address (#27997) 1 year ago
markup make writing main test easier (#27270) 1 year ago
migrations Bump google/go-github to v57 (#28514) 1 year ago
mirror Refactor deletion (#28610) 1 year ago
notify Update status and code index after changing the default branch (#27018) 1 year ago
org Delete repos of org when purge delete user (#27273) 1 year ago
packages Adjust object format interface (#28469) 1 year ago
pull Improve ObjectFormat interface (#28496) 1 year ago
release Refactor deletion (#28610) 1 year ago
repository Refactor deletion (#28610) 1 year ago
secrets Refactor deletion (#28610) 1 year ago
task Fix incorrect ctx usage in defer function (#27740) 1 year ago
uinotification Penultimate round of `db.DefaultContext` refactor (#27414) 1 year ago
user Refactor deletion (#28610) 1 year ago
webhook Abstract hash function usage (#28138) 1 year ago
wiki Adjust object format interface (#28469) 1 year ago