From 418ce504443c274d8ff344e902d86c3c12a57631 Mon Sep 17 00:00:00 2001 From: Anirudh Oppiliappan Date: Wed, 20 Aug 2025 20:45:41 +0300 Subject: [PATCH] knotserver: strip @ from ownerHandle in reject message Signed-off-by: Anirudh Oppiliappan --- knotserver/git.go | 1 + 1 file changed, 1 insertion(+) diff --git a/knotserver/git.go b/knotserver/git.go index cd75771d..a5c1263b 100644 --- a/knotserver/git.go +++ b/knotserver/git.go @@ -129,6 +129,7 @@ func (d *Handle) RejectPush(w http.ResponseWriter, r *http.Request, unqualifiedR // If the appview gave us the repository owner's handle we can attempt to // construct the correct ssh url. ownerHandle := r.Header.Get("x-tangled-repo-owner-handle") + ownerHandle = strings.TrimPrefix(ownerHandle, "@") if ownerHandle != "" && !strings.ContainsAny(ownerHandle, ":") { hostname := d.c.Server.Hostname if strings.Contains(hostname, ":") { -- 2.51.2