From 1efb5d5c997bf3d1ded0ae7af97ee0d0a754e03a Mon Sep 17 00:00:00 2001 From: Teal Dulcet Date: Wed, 8 Jan 2025 05:16:56 -0800 Subject: [PATCH] Fixed RET504 (unnecessary-assign): Unnecessary assignment to `v` before `return` statement --- tools/readable_bash.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tools/readable_bash.py b/tools/readable_bash.py index 3ccf1a37..a5e2b4ec 100644 --- a/tools/readable_bash.py +++ b/tools/readable_bash.py @@ -462,9 +462,8 @@ class BashScript(Grammar): v = re.sub(r"(\$?)PRIMARY_HOSTNAME", r"box.yourdomain.com", v) v = re.sub(r"\$STORAGE_ROOT", r"$STORE", v) - v = v.replace("`pwd`", "/path/to/mailinabox") + return v.replace("`pwd`", "/path/to/mailinabox") - return v def wrap_lines(text, cols=60): ret = ""