Skip to content

Commit

Permalink
Process expects array for command line to run
Browse files Browse the repository at this point in the history
  • Loading branch information
angelsk committed May 11, 2020
1 parent e83cf8a commit f7adb95
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/Updater/CommandCronManipulator.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,12 @@ public function __construct(ProcessRunner $processRunner, FileSystem $fileSystem
public function replace(string $contents): void
{
$filePath = $this->fileSystem->createTempFile('cron', $contents);
$this->processRunner->run($this->cronCommand . ' ' . $filePath);
$this->processRunner->run([$this->cronCommand, $filePath]);
$this->fileSystem->removeFile($filePath);
}

public function getContent(): string
{
return $this->processRunner->run($this->cronCommand . ' -l');
return $this->processRunner->run([$this->cronCommand, '-l']);
}
}

0 comments on commit f7adb95

Please sign in to comment.