| author | |
| committer | |
| log | 37bf4e6ec4f18fb94e7ec04436a947d14642a5b6 |
| tree | 7b6059faaa7eddced9cd67d6d7941a487ffb0c99 |
| parent | 31fb21009024e9476bda4705355d55491d7fd2ef |
| signature | Signed by PGP key B5690EEEBB952194 |
2 files changed, 0 insertions(+), 18 deletions(-)
apps/mobile/src/features/agent-awareness/remoteRegistration.test.ts-8| ... | ... | @@ -33,7 +33,6 @@ import { |
| 33 | 33 | mergeAgentAwarenessRegistrationPreferences, |
| 34 | 34 | refreshActiveLiveActivityRemoteRegistration, |
| 35 | 35 | refreshAgentAwarenessRegistration, |
| 36 | normalizeAgentAwarenessRelayBaseUrl, | |
| 37 | 36 | registerAgentAwarenessConnection, |
| 38 | 37 | registerLiveActivityPushToken, |
| 39 | 38 | releaseAgentAwarenessRelayTokenProvider, |
| ... | ... | @@ -363,13 +362,6 @@ describe("makeRelayDeviceRegistrationRequest", () => { |
| 363 | 362 | }); |
| 364 | 363 | }); |
| 365 | 364 | |
| 366 | it("normalizes relay base URLs for APNs registration requests", () => { | |
| 367 | expect(normalizeAgentAwarenessRelayBaseUrl(" https://relay.example.test/// ")).toBe( | |
| 368 | "https://relay.example.test", | |
| 369 | ); | |
| 370 | expect(normalizeAgentAwarenessRelayBaseUrl(" ")).toBeNull(); | |
| 371 | }); | |
| 372 | ||
| 373 | 365 | it("overrides persisted preferences for an in-flight registration", () => { |
| 374 | 366 | expect( |
| 375 | 367 | mergeAgentAwarenessRegistrationPreferences( |
apps/mobile/src/features/agent-awareness/remoteRegistration.ts-10| ... | ... | @@ -139,16 +139,6 @@ export function mergeAgentAwarenessRegistrationPreferences( |
| 139 | 139 | return { ...stored, ...override }; |
| 140 | 140 | } |
| 141 | 141 | |
| 142 | export function normalizeAgentAwarenessRelayBaseUrl( | |
| 143 | value: string | null | undefined, | |
| 144 | ): string | null { | |
| 145 | const trimmed = value?.trim(); | |
| 146 | if (!trimmed) { | |
| 147 | return null; | |
| 148 | } | |
| 149 | return trimmed.replace(/\/+$/g, ""); | |
| 150 | } | |
| 151 | ||
| 152 | 142 | function readRelayConfig(): { readonly url: string } | null { |
| 153 | 143 | const relayUrl = resolveCloudPublicConfig().relay.url; |
| 154 | 144 | if (!relayUrl) { |