From bbbdf01213b943ce7ef07e7b6d5f4f965013b102 Mon Sep 17 00:00:00 2001 From: tobi <31960611+tsmethurst@users.noreply.github.com> Date: Sat, 13 Jul 2024 11:07:01 +0200 Subject: [PATCH] [bugfix] Fix panic in `isStatusHomeTimelineable` (#3096) --- internal/filter/visibility/home_timeline.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/internal/filter/visibility/home_timeline.go b/internal/filter/visibility/home_timeline.go index 0a3fbde4e..af583a847 100644 --- a/internal/filter/visibility/home_timeline.go +++ b/internal/filter/visibility/home_timeline.go @@ -161,12 +161,13 @@ func (f *Filter) isStatusHomeTimelineable(ctx context.Context, owner *gtsmodel.A } // Fetch next parent in conversation. + inReplyToID := next.InReplyToID next, err = f.state.DB.GetStatusByID( gtscontext.SetBarebones(ctx), - next.InReplyToID, + inReplyToID, ) if err != nil { - return false, gtserror.Newf("error getting status parent %s: %w", next.InReplyToID, err) + return false, gtserror.Newf("error getting status parent %s: %w", inReplyToID, err) } }