Fix wrong logger call

Introduced in 048a31e348.

Signed-off-by: JoeLametta <JoeLametta@users.noreply.github.com>
This commit is contained in:
JoeLametta
2019-10-26 08:00:00 +00:00
parent 4569644335
commit 87a477a5d6

View File

@@ -14,8 +14,8 @@ def eject_device(device):
# `eject device` prints nothing to stdout
subprocess.check_output(['eject', device], stderr=subprocess.STDOUT)
except subprocess.CalledProcessError as e:
logger.warning(e.cmd, 'returned with exit code: ', e.returncode,
e.output)
logger.warning("command '%s' returned with exit code '%d' (%s)",
' '.join(e.cmd), e.returncode, e.output.rstrip())
def load_device(device):
@@ -28,8 +28,8 @@ def load_device(device):
subprocess.check_output(['eject', '-t', device],
stderr=subprocess.STDOUT)
except subprocess.CalledProcessError as e:
logger.warning(e.cmd, 'returned with exit code: ', e.returncode,
e.output)
logger.warning("command '%s' returned with exit code '%d' (%s)",
' '.join(e.cmd), e.returncode, e.output.rstrip())
def unmount_device(device):