Skip to content

Commit 06821b7

Browse files
authored
Better check before removing crons for magento2 recipe
1 parent bbd950d commit 06821b7

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

recipe/magento2.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -595,7 +595,7 @@ function magentoDeployAssetsSplit(string $area): void
595595
*/
596596
desc('Remove cron from crontab and kill running cron jobs');
597597
task('magento:cron:stop', function () {
598-
if (has('previous_release')) {
598+
if (has('previous_release') && test("[ -f {{previous_release}}/{{magento_dir}}/bin/magento ]")) {
599599
run('{{bin/php}} {{previous_release}}/{{magento_dir}}/bin/magento cron:remove');
600600
}
601601

0 commit comments

Comments
 (0)