mirror of
https://github.com/go-gitea/gitea.git
synced 2025-08-31 13:02:52 +09:00
Virtual user gitea-bots
This commit is contained in:
@ -577,6 +577,13 @@ func (u *User) IsGhost() bool {
|
||||
return u.ID == -1 && u.Name == "Ghost"
|
||||
}
|
||||
|
||||
func (u *User) IsBots() bool {
|
||||
if u == nil {
|
||||
return false
|
||||
}
|
||||
return u.ID == -2 && u.Name == "gitea-bots"
|
||||
}
|
||||
|
||||
var (
|
||||
reservedUsernames = []string{
|
||||
".",
|
||||
|
Reference in New Issue
Block a user