Skip to content
This repository has been archived by the owner on Sep 5, 2020. It is now read-only.

exclude null values from locations #754

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/Rocketeer/Services/Connections/Shell/Modules/Binaries.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@ public function which($binary, $fallback = null, $prompt = true)
$locations[] = $fallback;
}

$locations = array_diff($locations, array(null));

// Add command prompt if possible
if ($this->hasCommand() && $prompt) {
$prompt = 'Binary "'.$binary.'" could not be found, please enter the path to it';
Expand Down