From f7323c065a086533ce8c7f0f0cb3f69a80539992 Mon Sep 17 00:00:00 2001 From: tobi <31960611+tsmethurst@users.noreply.github.com> Date: Sat, 26 Apr 2025 15:03:05 +0200 Subject: [feature] Update attachment format, receive + send `focalPoint` prop + use it on the frontend (#4052) * [feature] Update attachment format, receive + send `focalPoint` prop + use it on the frontend * whoops * boop * restore function signature of ExtractAttachments --- internal/filter/spam/statusable.go | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'internal/filter') diff --git a/internal/filter/spam/statusable.go b/internal/filter/spam/statusable.go index 3e9e51697..4fbd6d780 100644 --- a/internal/filter/spam/statusable.go +++ b/internal/filter/spam/statusable.go @@ -142,7 +142,14 @@ func (f *Filter) StatusableOK( } // HEURISTIC 6: Are there any media attachments? - attachments, _ := ap.ExtractAttachments(statusable) + attachments, err := ap.ExtractAttachments(statusable) + if err != nil { + log.Warnf(ctx, + "error(s) extracting attachments for %s: %v", + ap.GetJSONLDId(statusable), err, + ) + } + hasAttachments := len(attachments) != 0 if hasAttachments { err := errors.New("status has attachment(s)") -- cgit v1.2.3