gitea/models/user
Chongyi Zheng 7b8e418da1
Replace deprecated `math/rand` functions ()
Suggested by logs in 

- Remove `math/rand.Seed`
`rand.Seed is deprecated: As of Go 1.20 there is no reason to call Seed
with a random value.`
- Replace `math/rand.Read`
`rand.Read is deprecated: For almost all use cases, [crypto/rand.Read]
is more appropriate.`
- Replace `math/rand` with `math/rand/v2`, which is available since Go
1.22
..
avatar.go Replace -1 with GhostUserID ()
badge.go Add admin API route for managing user's badges ()
block.go Add user blocking ()
email_address.go Refactor DeleteInactiveUsers, fix bug and add tests ()
email_address_test.go migrate some more "OptionalBool" to "Option[bool]" ()
error.go Remove unused `KeyID`. ()
external_login_user.go Remove GetByBean method because sometimes it's danger when query condition parameter is zero and also introduce new generic methods ()
follow.go Add user blocking ()
follow_test.go Next round of `db.DefaultContext` refactor ()
list.go Reduce usage of `db.DefaultContext` ()
main_test.go make writing main test easier ()
must_change_password.go Add command to bulk set must-change-password ()
openid.go More refactoring of `db.DefaultContext` ()
openid_test.go More refactoring of `db.DefaultContext` ()
redirect.go Another round of `db.DefaultContext` refactor ()
redirect_test.go Another round of `db.DefaultContext` refactor ()
search.go migrate some more "OptionalBool" to "Option[bool]" ()
setting.go More refactoring of `db.DefaultContext` ()
setting_keys.go Show outdated comments in files changed tab ()
setting_test.go More refactoring of `db.DefaultContext` ()
user.go Improve oauth2 client "preferred username field" logic and the error handling ()
user_system.go Replace -1 with GhostUserID ()
user_test.go Replace deprecated `math/rand` functions ()
user_update.go Implement FSFE REUSE for golang files ()