diff options
author | 6543 <6543@obermui.de> | 2024-03-02 16:42:31 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-02 16:42:31 +0100 |
commit | a3f05d0d98408bb47333b19f505b21afcefa9e7c (patch) | |
tree | e4a1f8c48b45668ccdcb84fabc7fa77b47990bfa /routers/web/admin/users.go | |
parent | 3f081d4b54261c1b4ee4f1df40c610fdd9581ef2 (diff) | |
download | gitea-a3f05d0d98408bb47333b19f505b21afcefa9e7c.tar.gz gitea-a3f05d0d98408bb47333b19f505b21afcefa9e7c.zip |
remove util.OptionalBool and related functions (#29513)
and migrate affected code
_last refactoring bits to replace **util.OptionalBool** with
**optional.Option[bool]**_
Diffstat (limited to 'routers/web/admin/users.go')
-rw-r--r-- | routers/web/admin/users.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/routers/web/admin/users.go b/routers/web/admin/users.go index bbdbc820d7..ca47175401 100644 --- a/routers/web/admin/users.go +++ b/routers/web/admin/users.go @@ -96,7 +96,7 @@ func NewUser(ctx *context.Context) { ctx.Data["login_type"] = "0-0" sources, err := db.Find[auth.Source](ctx, auth.FindSourcesOptions{ - IsActive: util.OptionalBoolTrue, + IsActive: optional.Some(true), }) if err != nil { ctx.ServerError("auth.Sources", err) @@ -117,7 +117,7 @@ func NewUserPost(ctx *context.Context) { ctx.Data["AllowedUserVisibilityModes"] = setting.Service.AllowedUserVisibilityModesSlice.ToVisibleTypeSlice() sources, err := db.Find[auth.Source](ctx, auth.FindSourcesOptions{ - IsActive: util.OptionalBoolTrue, + IsActive: optional.Some(true), }) if err != nil { ctx.ServerError("auth.Sources", err) |