From ee26bc6061ababbc84db7b53e3a06bd651166cf5 Mon Sep 17 00:00:00 2001 From: Tulir Asokan Date: Mon, 12 Dec 2022 12:05:40 +0200 Subject: [PATCH] Prevent misusing --create-portals in sync command --- commands.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/commands.go b/commands.go index 1a631e8..b399eab 100644 --- a/commands.go +++ b/commands.go @@ -1110,6 +1110,10 @@ func fnSync(ce *WrappedCommandEvent) { ce.Reply("`--contact-avatars` can only be used with `sync contacts`") return } + if createPortals && !groups { + ce.Reply("`--create-portals` can only be used with `sync groups`") + return + } if appState { for _, name := range appstate.AllPatchNames {