diff options
Diffstat (limited to 'internal/federation/dereferencing/status.go')
-rw-r--r-- | internal/federation/dereferencing/status.go | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/internal/federation/dereferencing/status.go b/internal/federation/dereferencing/status.go index da4639c5d..56545c5e0 100644 --- a/internal/federation/dereferencing/status.go +++ b/internal/federation/dereferencing/status.go @@ -318,20 +318,20 @@ func (d *deref) populateStatusMentions(ctx context.Context, status *gtsmodel.Sta for _, m := range status.Mentions { if m.ID != "" { // we've already populated this mention, since it has an ID - log.Debug("populateStatusMentions: mention already populated") + log.Debug(ctx, "mention already populated") mentionIDs = append(mentionIDs, m.ID) newMentions = append(newMentions, m) continue } if m.TargetAccountURI == "" { - log.Debug("populateStatusMentions: target URI not set on mention") + log.Debug(ctx, "target URI not set on mention") continue } targetAccountURI, err := url.Parse(m.TargetAccountURI) if err != nil { - log.Debugf("populateStatusMentions: error parsing mentioned account uri %s: %s", m.TargetAccountURI, err) + log.Debugf(ctx, "error parsing mentioned account uri %s: %s", m.TargetAccountURI, err) continue } @@ -342,7 +342,7 @@ func (d *deref) populateStatusMentions(ctx context.Context, status *gtsmodel.Sta if a, err := d.db.GetAccountByURI(ctx, targetAccountURI.String()); err != nil { errs = append(errs, err.Error()) } else { - log.Debugf("populateStatusMentions: got target account %s with id %s through GetAccountByURI", targetAccountURI, a.ID) + log.Debugf(ctx, "got target account %s with id %s through GetAccountByURI", targetAccountURI, a.ID) targetAccount = a } @@ -352,13 +352,13 @@ func (d *deref) populateStatusMentions(ctx context.Context, status *gtsmodel.Sta if a, err := d.GetAccountByURI(ctx, requestingUsername, targetAccountURI, false); err != nil { errs = append(errs, err.Error()) } else { - log.Debugf("populateStatusMentions: got target account %s with id %s through GetRemoteAccount", targetAccountURI, a.ID) + log.Debugf(ctx, "got target account %s with id %s through GetRemoteAccount", targetAccountURI, a.ID) targetAccount = a } } if targetAccount == nil { - log.Debugf("populateStatusMentions: couldn't get target account %s: %s", m.TargetAccountURI, strings.Join(errs, " : ")) + log.Debugf(ctx, "couldn't get target account %s: %s", m.TargetAccountURI, strings.Join(errs, " : ")) continue } @@ -419,13 +419,13 @@ func (d *deref) populateStatusAttachments(ctx context.Context, status *gtsmodel. Blurhash: &a.Blurhash, }) if err != nil { - log.Errorf("populateStatusAttachments: couldn't get remote media %s: %s", a.RemoteURL, err) + log.Errorf(ctx, "couldn't get remote media %s: %s", a.RemoteURL, err) continue } attachment, err := processingMedia.LoadAttachment(ctx) if err != nil { - log.Errorf("populateStatusAttachments: couldn't load remote attachment %s: %s", a.RemoteURL, err) + log.Errorf(ctx, "couldn't load remote attachment %s: %s", a.RemoteURL, err) continue } |