mirror of
https://github.com/superseriousbusiness/gotosocial
synced 2025-06-05 21:59:39 +02:00
[performance] use GetAccountByUsernameDomain() for local account lookups to rely on cache (#793)
Signed-off-by: kim <grufwub@gmail.com> Signed-off-by: kim <grufwub@gmail.com>
This commit is contained in:
@@ -157,7 +157,7 @@ func (f *federator) AuthenticatePostInbox(ctx context.Context, w http.ResponseWr
|
||||
return nil, false, errors.New("username was empty")
|
||||
}
|
||||
|
||||
receivingAccount, err := f.db.GetLocalAccountByUsername(ctx, username)
|
||||
receivingAccount, err := f.db.GetAccountByUsernameDomain(ctx, username, "")
|
||||
if err != nil {
|
||||
return nil, false, fmt.Errorf("could not fetch receiving account with username %s: %s", username, err)
|
||||
}
|
||||
|
Reference in New Issue
Block a user