Skip to content

Commit

Permalink
Ensures app/Twill/Capsules exists during install
Browse files Browse the repository at this point in the history
  • Loading branch information
antonioribeiro authored and ifox committed May 24, 2021
1 parent 1ad2e50 commit deff0a8
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/Commands/CapsuleInstall.php
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,8 @@ protected function cleanTempFile()

protected function getTempFileName()
{
$this->makeDir($this->capsule['base_path']);

return $this->capsule['base_path'] . '/install.zip';
}

Expand Down Expand Up @@ -403,4 +405,11 @@ public function renameToCapsule()

return file_exists($destination);
}

public function makeDir($path)
{
if (!file_exists($path)) {
mkdir($path, 0775, true);
}
}
}

0 comments on commit deff0a8

Please sign in to comment.