From 2d497bc74c943e5f3daf00f1304d6d8dda303425 Mon Sep 17 00:00:00 2001 From: Michael Black Date: Mon, 22 Jun 2026 14:44:48 -0500 Subject: [PATCH] isPartOf URL should only use canonical handle-form --- bskyweb/cmd/bskyweb/server.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/bskyweb/cmd/bskyweb/server.go b/bskyweb/cmd/bskyweb/server.go index 0df76dc45a..7c36b72560 100644 --- a/bskyweb/cmd/bskyweb/server.go +++ b/bskyweb/cmd/bskyweb/server.go @@ -705,7 +705,10 @@ func (srv *Server) WebPost(c echo.Context) error { if posts, perr := appbsky.FeedGetPosts(pctx, srv.xrpcc, []string{rootURI}); perr != nil { log.Warnf("failed to resolve thread root post for isPartOf: %s\t%v", rootURI, perr) } else if len(posts.Posts) > 0 && posts.Posts[0].Author != nil { - isPartOfURL = bskyPostURLFromATURIWithDIDFallback(posts.Posts[0].Author.Handle, rootURI) + // Handle-form only (no DID fallback): isPartOf must match the + // root page's handle-form canonical, so an unusable handle omits + // isPartOf rather than point at a non-canonical DID-form URL. + isPartOfURL = bskyPostURLFromATURI(posts.Posts[0].Author.Handle, rootURI) } cancel() }