From 20596c1d96eae389ff7ad9d55b695a80bcc29683 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Tue, 6 Jan 2026 16:30:09 +0000 Subject: [PATCH] Move hyphen to end of character class for cleaner regex Co-authored-by: TingluoHuang <1750815+TingluoHuang@users.noreply.github.com> --- packages/http-client/src/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/http-client/src/index.ts b/packages/http-client/src/index.ts index 1512c2cd..80d81aed 100644 --- a/packages/http-client/src/index.ts +++ b/packages/http-client/src/index.ts @@ -822,7 +822,7 @@ export class HttpClient { if (orchId) { // Sanitize the orchestration ID to ensure it contains only valid token characters // Valid characters: alphanumeric, !, #, $, %, &, ', *, +, -, ., ^, _, `, |, ~ - const sanitizedId = orchId.replace(/[^a-zA-Z0-9!#$%&'*+.\-^_`|~]/g, '_') + const sanitizedId = orchId.replace(/[^a-zA-Z0-9!#$%&'*+.^_`|~-]/g, '_') return `${userAgent} github_orchestration_id/${sanitizedId}` } return userAgent