(options: {
readonly key: string;
readonly oauthHost?: string | undefined;
})
| 253 | } |
| 254 | |
| 255 | function persistedOAuthHost(options: { |
| 256 | readonly key: string; |
| 257 | readonly oauthHost?: string | undefined; |
| 258 | }): string | undefined { |
| 259 | const oauthHost = options.oauthHost; |
| 260 | const normalized = normalizeEndpoint(oauthHost ?? DEFAULT_KIMI_CODE_OAUTH_HOST); |
| 261 | if ( |
| 262 | options.key === KIMI_CODE_OAUTH_KEY && |
| 263 | normalized === normalizeEndpoint(DEFAULT_KIMI_CODE_OAUTH_HOST) |
| 264 | ) { |
| 265 | return undefined; |
| 266 | } |
| 267 | return normalized; |
| 268 | } |
| 269 | |
| 270 | function managedOAuthRef(options: { |
| 271 | readonly key: string; |
no test coverage detected