]> git.0d.be Git - django-panik-nonstop.git/commitdiff
stamina: remove unnessary cmd string case as it was used for sleep debug
authorFrédéric Péters <fpeters@0d.be>
Wed, 19 Aug 2020 12:27:03 +0000 (14:27 +0200)
committerFrédéric Péters <fpeters@0d.be>
Wed, 19 Aug 2020 12:27:15 +0000 (14:27 +0200)
nonstop/management/commands/stamina.py

index e66844527f0c73b9a257f8fbd3f0c9e76b1276f8..3c80df0662dd251832395beacf3c2216329dad9f 100644 (file)
@@ -195,13 +195,7 @@ class Command(BaseCommand):
             cmd.append(item.file_path())
             logger.info('Play file: %s', item.file_path())
         logger.debug('cmd %r', cmd)
-        if isinstance(cmd, str):
-            self.player = await asyncio.create_subprocess_shell(
-                    cmd,
-                    stdout=asyncio.subprocess.PIPE,
-                    stderr=asyncio.subprocess.PIPE)
-        else:
-            self.player = await asyncio.create_subprocess_exec(
+        self.player = await asyncio.create_subprocess_exec(
                     *cmd,
                     stdout=asyncio.subprocess.PIPE,
                     stderr=asyncio.subprocess.PIPE)