We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f7072a5 commit d775901Copy full SHA for d775901
Cron/ScheduleJob.php
@@ -56,6 +56,12 @@ private function getCronTimestamp(): int
56
{
57
$version = $this->productMetadata->getVersion();
58
59
+ // When running on a version of Magento in development by cloning the repo,
60
+ // the version will be for example 'dev-2.4-develop',
61
+ // stripping of 'dev-' from the start will still execute the correct version check here
62
+ // '?:' exists to satisfy static tests because preg_replace could potentially return 'null'
63
+ $version = preg_replace('/^dev\-/', '', $version) ?: $version;
64
+
65
if (version_compare($version, '2.2.0') >= 0) {
66
return $this->dateTime->gmtTimestamp();
67
}
0 commit comments