mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2026-01-07 12:13:17 -06:00
rename target => receiving account
This commit is contained in:
parent
3965ae0d3f
commit
84616b07ff
8 changed files with 42 additions and 57 deletions
|
|
@ -56,12 +56,9 @@ func (f *federatingDB) Update(ctx context.Context, asType vocab.Type) error {
|
|||
l.Debug("entering Update")
|
||||
}
|
||||
|
||||
targetAcct, fromFederatorChan, err := extractFromCtx(ctx)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if targetAcct == nil || fromFederatorChan == nil {
|
||||
// If the target account or federator channel wasn't set on the context, that means this request didn't pass
|
||||
receivingAccount, _, fromFederatorChan := extractFromCtx(ctx)
|
||||
if receivingAccount == nil || fromFederatorChan == nil {
|
||||
// If the receiving account or federator channel wasn't set on the context, that means this request didn't pass
|
||||
// through the API, but came from inside GtS as the result of another activity on this instance. That being so,
|
||||
// we can safely just ignore this activity, since we know we've already processed it elsewhere.
|
||||
return nil
|
||||
|
|
@ -153,7 +150,7 @@ func (f *federatingDB) Update(ctx context.Context, asType vocab.Type) error {
|
|||
APObjectType: ap.ObjectProfile,
|
||||
APActivityType: ap.ActivityUpdate,
|
||||
GTSModel: updatedAcct,
|
||||
ReceivingAccount: targetAcct,
|
||||
ReceivingAccount: receivingAccount,
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue