Merge pull request #3941 from beganovich/v2-undo-setup-changes

Undo setup changes
This commit is contained in:
David Bomba 2020-07-28 22:44:35 +10:00 committed by GitHub
commit b20c0a5ff0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -60,14 +60,6 @@ class SystemHealth
$system_health = false; $system_health = false;
} }
if (!self::checkNode()) {
$system_health = false;
}
if (!self::checkNpm()) {
$system_health = false;
}
return [ return [
'system_health' => $system_health, 'system_health' => $system_health,
'extensions' => self::extensions(), 'extensions' => self::extensions(),
@ -90,13 +82,14 @@ class SystemHealth
exec('node -v', $foo, $exitCode); exec('node -v', $foo, $exitCode);
if ($exitCode === 0) { if ($exitCode === 0) {
return true; return $foo[0];
} }
return false;
} catch (\Exception $e) { } catch (\Exception $e) {
return false;
return false;
} }
} }
public static function checkNpm() public static function checkNpm()
@ -105,14 +98,14 @@ class SystemHealth
exec('npm -v', $foo, $exitCode); exec('npm -v', $foo, $exitCode);
if ($exitCode === 0) { if ($exitCode === 0) {
return true; return $foo[0];
} }
return false; }catch (\Exception $e) {
} catch (\Exception $e) { return false;
return false;
} }
} }
private static function simpleDbCheck() :bool private static function simpleDbCheck() :bool