From 1d87180d0284f4ac661b1ce9c10b64807abeaf23 Mon Sep 17 00:00:00 2001 From: Dan Wallis Date: Sun, 5 Mar 2023 14:32:34 +0000 Subject: [PATCH] Fix case when jshint is not available --- src/Standards/Generic/Sniffs/Debug/JSHintSniff.php | 2 +- src/Standards/Generic/Tests/Debug/JSHintUnitTest.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Standards/Generic/Sniffs/Debug/JSHintSniff.php b/src/Standards/Generic/Sniffs/Debug/JSHintSniff.php index 06de35940a..738ab67ebe 100644 --- a/src/Standards/Generic/Sniffs/Debug/JSHintSniff.php +++ b/src/Standards/Generic/Sniffs/Debug/JSHintSniff.php @@ -52,7 +52,7 @@ public function process(File $phpcsFile, $stackPtr) { $rhinoPath = Config::getExecutablePath('rhino'); $jshintPath = Config::getExecutablePath('jshint'); - if ($rhinoPath === null && $jshintPath === null) { + if ($jshintPath === null) { return; } diff --git a/src/Standards/Generic/Tests/Debug/JSHintUnitTest.php b/src/Standards/Generic/Tests/Debug/JSHintUnitTest.php index 618465a916..6a10e2ad8b 100644 --- a/src/Standards/Generic/Tests/Debug/JSHintUnitTest.php +++ b/src/Standards/Generic/Tests/Debug/JSHintUnitTest.php @@ -25,7 +25,7 @@ protected function shouldSkipTest() { $rhinoPath = Config::getExecutablePath('rhino'); $jshintPath = Config::getExecutablePath('jshint'); - if ($rhinoPath === null && $jshintPath === null) { + if ($jshintPath === null) { return true; }