fix(config): tolerate missing facade boundary config

This commit is contained in:
Vincent Koc
2026-04-02 23:02:21 +09:00
parent e0d20966ae
commit 4f692190b4
3 changed files with 12 additions and 11 deletions

View File

@@ -115,10 +115,10 @@ function hasEnvConfiguredChannel(env: NodeJS.ProcessEnv): boolean {
}
export function hasPotentialConfiguredChannels(
cfg: OpenClawConfig,
cfg: OpenClawConfig | null | undefined,
env: NodeJS.ProcessEnv = process.env,
): boolean {
const channels = isRecord(cfg.channels) ? cfg.channels : null;
const channels = isRecord(cfg?.channels) ? cfg.channels : null;
if (channels) {
for (const [key, value] of Object.entries(channels)) {
if (IGNORED_CHANNEL_CONFIG_KEYS.has(key)) {