mirror of
https://github.com/go-gitea/gitea
synced 2025-07-16 07:18:37 +00:00
migrate from com.* to alternatives (#14103)
* remove github.com/unknwon/com from models * dont use "com.ToStr()" * replace "com.ToStr" with "fmt.Sprint" where its easy to do * more refactor * fix test * just "proxy" Copy func for now * as per @lunny
This commit is contained in:
@@ -15,8 +15,6 @@ import (
|
||||
"code.gitea.io/gitea/modules/convert"
|
||||
api "code.gitea.io/gitea/modules/structs"
|
||||
"code.gitea.io/gitea/routers/api/v1/utils"
|
||||
|
||||
"github.com/unknwon/com"
|
||||
)
|
||||
|
||||
// Search search users
|
||||
@@ -61,7 +59,7 @@ func Search(ctx *context.APIContext) {
|
||||
|
||||
opts := &models.SearchUserOptions{
|
||||
Keyword: strings.Trim(ctx.Query("q"), " "),
|
||||
UID: com.StrTo(ctx.Query("uid")).MustInt64(),
|
||||
UID: ctx.QueryInt64("uid"),
|
||||
Type: models.UserTypeIndividual,
|
||||
ListOptions: listOptions,
|
||||
}
|
||||
|
Reference in New Issue
Block a user