diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 153f9f2..91d72ed 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,5 +1,5 @@ name: Self update testing -on: push +on: [push, pull_request] jobs: # Checkout in separate job because docker image is alpine based and checkout action doesn't work. functional: diff --git a/src/SelfUpdateCommand.php b/src/SelfUpdateCommand.php index 8639773..276b902 100644 --- a/src/SelfUpdateCommand.php +++ b/src/SelfUpdateCommand.php @@ -150,7 +150,7 @@ public function getLatestReleaseFromGithub(array $options) continue; } - if (!$options['preview'] && (VersionParser::parseStability($releaseVersion) !== 'stable') || $release['prerelease']) { + if (!$options['preview'] && ((VersionParser::parseStability($releaseVersion) !== 'stable') || $release['prerelease'])) { // If preview not requested and current version is not stable, look for the next one. continue; }