Files
openclaw/src/routing/default-account-warnings.ts
Sid 4ffe15c6b2 fix(telegram): warn when accounts.default is missing in multi-account setup (#32544)
Merged via squash.

Prepared head SHA: 7ebc3f65b2
Co-authored-by: Sid-Qin <201593046+Sid-Qin@users.noreply.github.com>
Co-authored-by: gumadeiras <5599352+gumadeiras@users.noreply.github.com>
Reviewed-by: @gumadeiras
2026-03-03 03:27:19 -05:00

18 lines
737 B
TypeScript

export function formatChannelDefaultAccountPath(channelKey: string): string {
return `channels.${channelKey}.defaultAccount`;
}
export function formatChannelAccountsDefaultPath(channelKey: string): string {
return `channels.${channelKey}.accounts.default`;
}
export function formatSetExplicitDefaultInstruction(channelKey: string): string {
return `Set ${formatChannelDefaultAccountPath(channelKey)} or add ${formatChannelAccountsDefaultPath(channelKey)}`;
}
export function formatSetExplicitDefaultToConfiguredInstruction(params: {
channelKey: string;
}): string {
return `Set ${formatChannelDefaultAccountPath(params.channelKey)} to one of these accounts, or add ${formatChannelAccountsDefaultPath(params.channelKey)}`;
}