From 2c65fbc9ccbc60851da549afd88113b1f6ad55d4 Mon Sep 17 00:00:00 2001 From: Anirudh Oppiliappan Date: Fri, 13 Feb 2026 17:43:12 +0200 Subject: [PATCH] appview/pulls: check if record.Source is nil It will be for patch pulls. Prevents a nil pointer deref when we set newSourceRev. --- appview/pulls/pulls.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/appview/pulls/pulls.go b/appview/pulls/pulls.go index 6a55157f..a27115ef 100644 --- a/appview/pulls/pulls.go +++ b/appview/pulls/pulls.go @@ -1915,7 +1915,10 @@ func (s *Pulls) resubmitPullHelper( record := pull.AsRecord() record.PatchBlob = blob.Blob record.CreatedAt = time.Now().Format(time.RFC3339) - record.Source.Sha = newSourceRev + + if record.Source != nil { + record.Source.Sha = newSourceRev + } _, err = comatproto.RepoPutRecord(r.Context(), client, &comatproto.RepoPutRecord_Input{ Collection: tangled.RepoPullNSID, -- 2.51.2