fix: stop hardcoded channel fallback and auto-pick sole configured channel (#23357) (thanks @lbo728)

Co-authored-by: lbo728 <extreme0728@gmail.com>
This commit is contained in:
Peter Steinberger
2026-02-22 11:20:33 +01:00
parent e33d7fcd13
commit 1cd3b30907
18 changed files with 355 additions and 91 deletions

View File

@@ -221,7 +221,7 @@ export function registerChannelsCli(program: Command) {
channels
.command("login")
.description("Link a channel account (if supported)")
.option("--channel <channel>", "Channel alias (default: whatsapp)")
.option("--channel <channel>", "Channel alias (auto when only one is configured)")
.option("--account <id>", "Account id (accountId)")
.option("--verbose", "Verbose connection logs", false)
.action(async (opts) => {
@@ -240,7 +240,7 @@ export function registerChannelsCli(program: Command) {
channels
.command("logout")
.description("Log out of a channel session (if supported)")
.option("--channel <channel>", "Channel alias (default: whatsapp)")
.option("--channel <channel>", "Channel alias (auto when only one is configured)")
.option("--account <id>", "Account id (accountId)")
.action(async (opts) => {
await runChannelsCommandWithDanger(async () => {