admin: improve perl detection

Signed-off-by: Varun Patil <radialapps@gmail.com>
pull/807/head
Varun Patil 2023-09-03 13:30:31 -07:00
parent 134e0f3748
commit 50dfffc0f8
1 changed files with 4 additions and 1 deletions

View File

@ -100,7 +100,10 @@ class AdminController extends GenericApiController
);
// Check for system perl
$status['perl'] = $this->getExecutableStatus(exec('which perl'), static fn ($p) => BinExt::testSystemPerl($p));
$status['perl'] = $this->getExecutableStatus(
trim(shell_exec('which perl') ?: '/bin/perl'),
static fn ($p) => BinExt::testSystemPerl($p)
);
// Check number of indexed files
$status['indexed_count'] = $index->getIndexedCount();