Make sure all args are strings

This commit is contained in:
Antoine Nguyen
2026-02-20 22:29:03 +01:00
parent 5effff7ddf
commit 0d8fc455cb
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -111,7 +111,7 @@ class SpamassassinClient:
self._learn_cmd_kwargs = {} self._learn_cmd_kwargs = {}
self._expected_exit_codes = [5, 6] self._expected_exit_codes = [5, 6]
def _find_binary(self, name): def _find_binary(self, name: str) -> str:
"""Find path to binary.""" """Find path to binary."""
code, output = exec_cmd(f"which {name}", shell=True) code, output = exec_cmd(f"which {name}", shell=True)
if not code: if not code:
@@ -134,7 +134,7 @@ class SpamassassinClient:
"-d", "-d",
self.conf["spamd_address"], self.conf["spamd_address"],
"-p", "-p",
self.conf["spamd_port"], str(self.conf["spamd_port"]),
"-L", "-L",
mtype, mtype,
"-u", "-u",
+1 -1
View File
@@ -61,7 +61,7 @@ class ScheduledMessage(models.Model):
constants.MAILBOX_NAME_SCHEDULED, constants.MAILBOX_NAME_SCHEDULED,
"header", "header",
constants.CUSTOM_HEADER_SCHEDULED_ID, constants.CUSTOM_HEADER_SCHEDULED_ID,
self.id, str(self.id),
] ]
) )
if code: if code: