mirror of
https://github.com/go-gitea/gitea
synced 2025-07-22 18:28:37 +00:00
Replace -1 with GhostUserID (#27703)
This commit is contained in:
@@ -27,7 +27,7 @@ func AvatarByUserName(ctx *context.Context) {
|
||||
size := int(ctx.ParamsInt64(":size"))
|
||||
|
||||
var user *user_model.User
|
||||
if strings.ToLower(userName) != "ghost" {
|
||||
if strings.ToLower(userName) != user_model.GhostUserLowerName {
|
||||
var err error
|
||||
if user, err = user_model.GetUserByName(ctx, userName); err != nil {
|
||||
if user_model.IsErrUserNotExist(err) {
|
||||
|
Reference in New Issue
Block a user