mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-11-09 02:07:30 -06:00
[bugfix] Fix setting bot on/off
This commit is contained in:
parent
e032c959e1
commit
e89ce8d43b
5 changed files with 88 additions and 22 deletions
|
|
@ -77,8 +77,16 @@ func (p *Processor) Update(ctx context.Context, account *gtsmodel.Account, form
|
|||
acctColumns = append(acctColumns, "discoverable")
|
||||
}
|
||||
|
||||
if form.Bot != nil {
|
||||
account.ActorType = gtsmodel.AccountActorTypeService
|
||||
if bot := form.Bot; bot != nil {
|
||||
if *bot {
|
||||
// Mark account as an Application.
|
||||
// See: https://www.w3.org/TR/activitystreams-vocabulary/#dfn-application
|
||||
account.ActorType = gtsmodel.AccountActorTypeApplication
|
||||
} else {
|
||||
// Mark account as a Person.
|
||||
// See: https://www.w3.org/TR/activitystreams-vocabulary/#dfn-person
|
||||
account.ActorType = gtsmodel.AccountActorTypePerson
|
||||
}
|
||||
acctColumns = append(acctColumns, "actor_type")
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue