From d17640a28364f77b44f174c9b18ea3a89c9b1637 Mon Sep 17 00:00:00 2001 From: Codex Date: Thu, 22 Oct 2026 21:15:41 +0300 Subject: [PATCH] Handle optional OAuth config in visibility regression assertion --- server/src/dtos/config.dto.spec.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/src/dtos/config.dto.spec.ts b/server/src/dtos/config.dto.spec.ts index 8eca6053e..8b2cf4a7a 100644 --- a/server/src/dtos/config.dto.spec.ts +++ b/server/src/dtos/config.dto.spec.ts @@ -44,7 +44,7 @@ describe('config visibility', () => { ...defaults, oauth: { ...defaults.oauth, accountManagementUrl: 'https://accounts.example.com', clientSecret: 'private' }, }; - expect(mapUserConfig(config).oauth.accountManagementUrl).toBe('https://accounts.example.com'); + expect(mapUserConfig(config).oauth?.accountManagementUrl).toBe('https://accounts.example.com'); expect(mapUserConfig(config).oauth).not.toHaveProperty('clientSecret'); expect(mapPublicConfig(config).oauth).not.toHaveProperty('accountManagementUrl'); expect(mapPublicConfig(config).oauth).not.toHaveProperty('clientSecret');