From 9ef53178b10527169703e732bdf430a8f064af20 Mon Sep 17 00:00:00 2001 From: Zevaryx Date: Tue, 19 Apr 2022 18:30:22 -0600 Subject: [PATCH] Change console arg context based on context type --- jarvis/client.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/jarvis/client.py b/jarvis/client.py index 357cadc..7c1cdb1 100644 --- a/jarvis/client.py +++ b/jarvis/client.py @@ -84,8 +84,9 @@ class Jarvis(Snake): name = ctx.invoked_name if isinstance(ctx, InteractionContext) and ctx.target_id: kwargs["context target"] = ctx.target - args = " ".join(f"{k}:{v}" for k, v in kwargs.items()) - args += " " + " ".join(args) + args = " ".join(f"{k}:{v}" for k, v in kwargs.items()) + elif isinstance(ctx, MessageContext): + args = " ".join(args) self.logger.debug(f"Running command `{name}` with args: {args or 'None'}") async def _sync_domains(self) -> None: