diff --git a/lib/core/agent.py b/lib/core/agent.py index 601ccf529..b4cf4cbba 100644 --- a/lib/core/agent.py +++ b/lib/core/agent.py @@ -193,10 +193,8 @@ class Agent: if where == PAYLOAD.WHERE.REPLACE: pass - elif kb.injection.suffix is not None: - expression += " %s" % kb.injection.suffix - elif suffix is not None: - expression += " %s" % suffix + elif any([kb.injection.suffix, suffix]): + expression += " %s" % (kb.injection.suffix or suffix) return expression